File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
2+ #
3+ # find exercises without a generator template (or txt file)
4+ # exclude deprecated exercises
5+ # exclude exercises with no canonical data
6+
7+ filter_deprecated () {
8+ grep -vFxf <(
9+ jq -r ' .exercises.practice[] | select(.status == "deprecated") | .slug' config.json
10+ )
11+ }
12+
13+ filter_canonical () {
14+ local probspec=" ${XDG_CACHE_HOME:- $HOME / .cache} /exercism/configlet/problem-specifications"
15+ if [[ -d $probspec ]]; then
16+ grep -vFxf <(
17+ find " $probspec /exercises" -mindepth 1 -type d \
18+ \! -exec test -f ' {}/canonical-data.json' \; \
19+ -exec basename ' {}' \;
20+ )
21+ else
22+ cat
23+ fi
24+ }
25+
26+ find exercises/practice/ -mindepth 2 -type d -path ' */.meta' \! -exec bash -c ' [[ -f "$0"/template.j2 || -f "$0"/template.txt ]]' ' {}' \; -print \
27+ | cut -d / -f 3 \
28+ | filter_deprecated \
29+ | filter_canonical \
30+ | sort
Original file line number Diff line number Diff line change 1+ Honestly, why would you template this one?
Original file line number Diff line number Diff line change 1+ Opting not to template this one.
2+
3+ It is possible (see the Python track), but really messy and complicated.
4+
5+ I (@colinleach) just did a partial template for Julia, and it's more trouble than it's worth.
You can’t perform that action at this time.
0 commit comments