{"id":110,"date":"2004-09-20T23:43:10","date_gmt":"2004-09-20T21:43:10","guid":{"rendered":"http:\/\/frenchfragfactory.net\/ozh\/archives\/2004\/09\/20\/keeping-my-downloadplugins-directory-synched\/"},"modified":"2007-05-09T23:38:14","modified_gmt":"2007-05-09T21:38:15","slug":"keeping-my-downloadplugins-directory-synched","status":"publish","type":"post","link":"https:\/\/planetozh.com\/blog\/2004\/09\/keeping-my-downloadplugins-directory-synched\/","title":{"rendered":"Keeping my download\/plugins directory synch&#8217;ed"},"content":{"rendered":"<p>Just a tip I&#39;m posting here, more as a reminder for myself when I publish my next plugin, maybe it can be useful to a few :<\/p>\n<p>My actual wordpress plugins directory (wp-content\/plugins) contains plugins I&#39;m working on, and plugins I&#39;ve published. Here is my way of creating in my download directory (download\/plugins) a synched unprocessed .php highlighted copy of a plugin, as well as a .txt version. For example, my download directory contains a live non-working replica of my ip2nation plugin :<\/p>\n<ol>\n<li>In my \/download\/plugins dir, I create a file with the same name as the plugin : <a href=\"\/download\/plugins\/wp_ozh_ip2nation.php\">wp_ozh_ip2nation.php<\/a>\n<div class=\"igsh-code-box\" id=\"ig-sh-1\"><pre class=\"language-php line-numbers\" data-no-optimize=\"1\" data-cfasync=\"false\"><code class=\"language-php\">&lt;?php\r\n$file = &quot;\/home\/physical\/path\/to\/wp-content\/plugins\/wp_ozh_ip2nation.php&quot;;\r\nhighlight_file($file);\r\n?&gt;<\/code><\/pre><\/div>\n<\/li>\n<li>Then the <a href=\"\/download\/plugins\/wp_ozh_ip2nation.txt\">.txt<\/a> version :\n<div class=\"igsh-code-box\" id=\"ig-sh-2\"><pre class=\"language-none line-numbers\" data-no-optimize=\"1\" data-cfasync=\"false\"><code class=\"language-none\">ln -s \/home\/path\/to\/wp-content\/plugins\/wp_ozh_ip2nation.php wp_ozh_ip2nation.txt<\/code><\/pre><\/div>\n<\/li>\n<\/ol>\n<p>This way, changes I make to the real plugin are automatically duplicated to the non-working version anyone can see and download. Another way would be of course to use some file to show source like for example at <a href=\"http:\/\/www.huddledmasses.org\/wp-content\/plugins\/source.php?file=image-headlines.php\">Huddled Masses<\/a>, but I wanted something more minimalistic (beware of his source.php, it&#39;s not compatible with most PHP installation and needs a few rewrite)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>How to keep my download dir up to date<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[2,3,10,76,245],"class_list":["post-110","post","type-post","status-publish","format-standard","hentry","tag-code","tag-linux","tag-php","tag-tips","tag-wordpress"],"_links":{"self":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts\/110","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/comments?post=110"}],"version-history":[{"count":0,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts\/110\/revisions"}],"wp:attachment":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/media?parent=110"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/categories?post=110"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/tags?post=110"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}