{"id":1204,"date":"2022-03-12T19:33:08","date_gmt":"2022-03-12T19:33:08","guid":{"rendered":"https:\/\/jamj.org\/?p=1204"},"modified":"2022-03-12T19:33:08","modified_gmt":"2022-03-12T19:33:08","slug":"gnu-timeout","status":"publish","type":"post","link":"https:\/\/jamj.org\/index.php\/2022\/03\/12\/gnu-timeout\/","title":{"rendered":"Gnu &#8211; Timeout"},"content":{"rendered":"\n<p>This is one of those extremely useful commands that not many people know. Basically runs a shell command and exits when the time runs out. The format is as follows:<\/p>\n\n\n\n<p><code>timeout [OPTION] DURATION COMMAND [ARG]\u2026<\/code><\/p>\n\n\n\n<p>Lets see an example:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><code>timeout 10s top<\/code> : This starts the <em>top<\/em> utility waits for 10 seconds and quit. Simple. The sufixes are: <ul><li><code>s<\/code> for second<\/li><li><code>m<\/code> for minutes<\/li><li><code>h<\/code> for hours <\/li><li><code>d<\/code> for days<\/li><\/ul><\/li><\/ul>\n\n\n\n<p>As always, check the man page for more details and info. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>This is one of those extremely useful commands that not many people know. Basically runs a shell command and exits when the time runs out. The format is as follows: timeout [OPTION] DURATION COMMAND [ARG]\u2026 Lets see an example: timeout 10s top : This starts the top utility waits for 10 seconds and quit. Simple. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-1204","post","type-post","status-publish","format-standard","hentry","category-gnu"],"_links":{"self":[{"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/posts\/1204","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/comments?post=1204"}],"version-history":[{"count":0,"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/posts\/1204\/revisions"}],"wp:attachment":[{"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/media?parent=1204"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/categories?post=1204"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jamj.org\/index.php\/wp-json\/wp\/v2\/tags?post=1204"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}