aboutsummaryrefslogtreecommitdiff
path: root/src/ee/tools/templates
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2019-05-20 22:46:45 +0200
committerTrygve Laugstøl <trygvis@inamo.no>2019-05-20 22:53:42 +0200
commit5f3623b8dd26b37b9ea6011bf71467b2a608b5ff (patch)
tree00fdb064f9116c5bf307f8b9815500487d86482b /src/ee/tools/templates
parent148ff60aa5a211292661e16ddba0f6fced85f372 (diff)
downloadee-python-5f3623b8dd26b37b9ea6011bf71467b2a608b5ff.tar.gz
ee-python-5f3623b8dd26b37b9ea6011bf71467b2a608b5ff.tar.bz2
ee-python-5f3623b8dd26b37b9ea6011bf71467b2a608b5ff.tar.xz
ee-python-5f3623b8dd26b37b9ea6011bf71467b2a608b5ff.zip
common_fact_types: Adding key for footprint.
functions: o Changing the structure of the functions, they're now factories that will be given kwargs and must return a function that processes the parts. o Adding new function to default set; 'map_footprint' that maps the KiCAD footprints to common footprints. part_validate_parts: Using only common keys.
Diffstat (limited to 'src/ee/tools/templates')
-rw-r--r--src/ee/tools/templates/build.ninja.j212
1 files changed, 11 insertions, 1 deletions
diff --git a/src/ee/tools/templates/build.ninja.j2 b/src/ee/tools/templates/build.ninja.j2
index 1f9ba35..0aaa76f 100644
--- a/src/ee/tools/templates/build.ninja.j2
+++ b/src/ee/tools/templates/build.ninja.j2
@@ -26,12 +26,15 @@ rule pn-part-search-list
command = $ee pn-part-search-list --in $in --out $out --supplier $supplier
rule part-apply-function
- command = $ee part-apply-function --in $in --out $out $functions
+ command = $ee part-apply-function --in $in --out $out $functions $arguments
rule part-find-requirements
description = part-find-requirements
command = $ee part-find-requirements --in $in --out $out
+rule part-validate-parts
+ command = $ee part-validate-parts --in $in --out $out
+
rule digikey-search-parts
description = digikey-search-parts
command = $ee digikey-search-parts --in $in --out $out
@@ -83,8 +86,15 @@ build ee/sch.xml: part-apply-function ee/kicad-sch.xml
{%- else %}
functions = --function ee.kicad.functions.default
{%- endif %}
+{%- if project.cfg["kicad-project"]["function-arguments"] %}
+ arguments = --argument {{ project.cfg["kicad-project"]["function-arguments"] }}
+{%- else %}
+ arguments = --argument ""
+{%- endif %}
{%- endif %}
+build $report_dir/part-validate-parts.rst: part-validate-parts ee/sch.xml
+
build ee/requirements.xml: part-find-requirements ee/sch.xml
{% for s in distributors %}