{"id":49,"date":"2015-12-16T00:29:51","date_gmt":"2015-12-16T00:29:51","guid":{"rendered":"http:\/\/portal.venidera.com\/kb\/?p=49"},"modified":"2015-12-16T12:34:40","modified_gmt":"2015-12-16T12:34:40","slug":"how-to-setup-and-start-using-a-virtualenv","status":"publish","type":"post","link":"https:\/\/portal.venidera.com\/kb\/2015\/12\/16\/how-to-setup-and-start-using-a-virtualenv\/","title":{"rendered":"(English) How to setup and start using a VirtualEnv"},"content":{"rendered":"<p class=\"qtranxs-available-languages-message qtranxs-available-languages-message-pb\">Desculpe-nos, mas este texto est\u00e1 apenas dispon\u00edvel em <a href=\"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/posts\/49?lang=en\" class=\"qtranxs-available-language-link qtranxs-available-language-link-en\" title=\"English\">English<\/a>. For the sake of viewer convenience, the content is shown below in the alternative language. You may click the link to switch the active language.<\/p><p>First you need to install the following packages:<\/p>\n<ul>\n<li>Python<\/li>\n<li>Pip<\/li>\n<li>Virtualenv<\/li>\n<\/ul>\n<p>Now you need to follow these steps:<\/p>\n<p><code>cd \/home\/myuser\/myvenvs<br \/>\nvirtualenv --no-site-packages --distribute mynewvenv<\/code><\/p>\n<blockquote><p>If you want to use a custom version of python, use this command instead:<\/p>\n<p><code>virtualenv -p \/opt\/python-2.7.3\/bin\/python2.7 --no-site-packages --distribute mynewvenv<\/code><\/p>\n<p>Where \/opt\/python-2.7.3\/bin\/python2.7 is the python binary you want to use (virtualenv can get its dependencies and packages automatically from the binary references, so you don&#8217;t need to worry about this)<\/p><\/blockquote>\n<p>Now you can enter the newly created VirtualEnv:<\/p>\n<p><code>source .\/mynewvenv\/bin\/activate<\/code><\/p>\n<p>And, eventually, if you have a file called &#8220;DEPENDENCIES&#8221; or something similar (which was generated by running a &#8220;pip freeze > DEPENDENCIES&#8221; command), you may install those dependencies by using the following command:<\/p>\n<p><code>pip install -r DEPENDENCIES<\/code><\/p>\n<p>That&#8217;s it! Now you can start digging around in your new VirtualEnv.<\/p>","protected":false},"excerpt":{"rendered":"<p>Desculpe-nos, mas este texto est\u00e1 apenas dispon\u00edvel em English. For the sake of viewer convenience, the content is shown below in the alternative language. You may click the link to switch the active language.First you need to install the following packages: Python Pip Virtualenv Now you need to follow these steps: cd \/home\/myuser\/myvenvs virtualenv &#8211;no-site-packages  [&#8230;]<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-49","post","type-post","status-publish","format-standard","hentry","category-development"],"_links":{"self":[{"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/posts\/49","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/comments?post=49"}],"version-history":[{"count":2,"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/posts\/49\/revisions"}],"predecessor-version":[{"id":51,"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/posts\/49\/revisions\/51"}],"wp:attachment":[{"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/media?parent=49"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/categories?post=49"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/portal.venidera.com\/kb\/wp-json\/wp\/v2\/tags?post=49"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}