{"id":455,"date":"2010-03-11T10:26:52","date_gmt":"2010-03-11T18:26:52","guid":{"rendered":"http:\/\/www.visophyte.org\/blog\/?p=455"},"modified":"2010-03-11T10:26:52","modified_gmt":"2010-03-11T18:26:52","slug":"partial-posting-pymake-dataresults-to-a-couch","status":"publish","type":"post","link":"https:\/\/www.visophyte.org\/blog\/2010\/03\/11\/partial-posting-pymake-dataresults-to-a-couch\/","title":{"rendered":"partial: posting pymake data\/results to a couch"},"content":{"rendered":"<p><a href=\"http:\/\/www.visophyte.org\/blog\/wp-content\/uploads\/2010\/03\/pymake-in-couch.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-thumbnail wp-image-456\" title=\"pymake-in-couch\" src=\"http:\/\/www.visophyte.org\/blog\/wp-content\/uploads\/2010\/03\/pymake-in-couch-600x319.png\" alt=\"\" width=\"600\" height=\"319\" srcset=\"https:\/\/www.visophyte.org\/blog\/wp-content\/uploads\/2010\/03\/pymake-in-couch-600x319.png 600w, https:\/\/www.visophyte.org\/blog\/wp-content\/uploads\/2010\/03\/pymake-in-couch-300x159.png 300w, https:\/\/www.visophyte.org\/blog\/wp-content\/uploads\/2010\/03\/pymake-in-couch.png 948w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/a><\/p>\n<p>What it does:<\/p>\n<ul>\n<li>Adds a &#8220;&#8211;couch-json&#8221; option to <a href=\"http:\/\/benjamin.smedbergs.us\/blog\/\">bsmedberg<\/a>&#8216;s <a href=\"http:\/\/benjamin.smedbergs.us\/pymake\/\">pymake<\/a> that takes a URL that crams the state of (global, non-rule associated) variables into a couch document for each makefile context executed.\u00a0 Variables are grouped by general origin as well as specific Makefile origin where relevant.\u00a0 The code as it stands only tells you about make variables that were accessed because this cuts down on things you (I) don&#8217;t care about.\u00a0 (For example, if FOO and BAR are defined but only FOO is ever expanded, then only FOO goes in the couch document.)<\/li>\n<\/ul>\n<p>I think there&#8217;s a fair bit of potential in this (pushing &#8220;make -p&#8221; style data\/make output into couch), at least in situations where there&#8217;s no escaping make, you don&#8217;t already have usable\/appropriate tooling, and python\/<a href=\"http:\/\/couchdb.apache.org\/\">CouchDB<\/a>\/JSON is one of your religions.<\/p>\n<p>I&#8217;m hoping to avoid touching the mozilla build system in any meaningful fashion from here on out, so I am unlikely to work on this much more, but it could be useful to others, hence this post.\u00a0 The <a href=\"http:\/\/hg.mozilla.org\/users\/bugmail_asutherland.org\/opc-pymake\/\">repo is here<\/a>, check out the &#8220;understand&#8221; (p)branch.\u00a0 (The changes are not suitable for upstreaming as things stand.)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>What it does: Adds a &#8220;&#8211;couch-json&#8221; option to bsmedberg&#8216;s pymake that takes a URL that crams the state of (global, non-rule associated) variables into a couch document for each makefile context executed.\u00a0 Variables are grouped by general origin as well &hellip; <a href=\"https:\/\/www.visophyte.org\/blog\/2010\/03\/11\/partial-posting-pymake-dataresults-to-a-couch\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"footnotes":""},"categories":[3],"tags":[130,80],"class_list":["post-455","post","type-post","status-publish","format-standard","hentry","category-mozilla","tag-couchdb","tag-pymake"],"_links":{"self":[{"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/posts\/455","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/comments?post=455"}],"version-history":[{"count":4,"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/posts\/455\/revisions"}],"predecessor-version":[{"id":460,"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/posts\/455\/revisions\/460"}],"wp:attachment":[{"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/media?parent=455"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/categories?post=455"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.visophyte.org\/blog\/wp-json\/wp\/v2\/tags?post=455"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}