
{"id":19036,"date":"2022-07-30T23:18:52","date_gmt":"2022-07-30T17:48:52","guid":{"rendered":"https:\/\/beautifulworknew.wordpress.com\/?p=19036"},"modified":"2022-07-30T23:18:52","modified_gmt":"2022-07-30T17:48:52","slug":"setting-an-environment-variable","status":"publish","type":"post","link":"https:\/\/www.trueangle.org\/index.php\/2022\/07\/30\/setting-an-environment-variable\/","title":{"rendered":"Setting value to an environment  variable"},"content":{"rendered":"\n<p><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ls\nascii-table     avg.txt               case-changer.c  env-var-set.c     functions_ver2.c  output.c\nascii-table.c   avg-with-garbage.txt  env-var         exist.sh          mph-to-kph.c\nascii-table.md  case-changer          env-var.c       functions_ver1.c  mph-to-kph_v2.c\n$cat env-var-set.c \n#define _POSIX_C_SOURCE 200112L\n#include &lt;stdio.h&gt;\n#include &lt;stdlib.h&gt;\n\nint main(void)\n{\n    setenv(\"FULLNAME\", \"Jack-Benny\", 1);\n    printf(\"Your full name is %s\\n\", getenv(\"FULLNAME\"));\n    return 0;\n}\n$gcc env-var-set.c -o env-var-set\n\n$\n$.\/env-var-set \nYour full name is Jack-Benny\n$\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>$ls ascii-table avg.txt case-changer.c env-var-set.c functions_ver2.c output.c ascii-table.c avg-with-garbage.txt env-var exist.sh mph-to-kph.c ascii-table.md case-changer env-var.c functions_ver1.c mph-to-kph_v2.c $cat env-var-set.c #define _POSIX_C_SOURCE 200112L #include &lt;stdio.h&gt; #include &lt;stdlib.h&gt; int main(void) { setenv(&#8220;FULLNAME&#8221;, &#8220;Jack-Benny&#8221;, 1); printf(&#8220;Your full name is %s\\n&#8221;, getenv(&#8220;FULLNAME&#8221;)); return 0; } $gcc env-var-set.c -o env-var-set $ $.\/env-var-set Your full name is Jack-Benny $<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/posts\/19036"}],"collection":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/comments?post=19036"}],"version-history":[{"count":0,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/posts\/19036\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/media?parent=19036"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/categories?post=19036"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/tags?post=19036"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}