mirror of https://github.com/Wilfred/difftastic/
30 lines
610 B
Bash
30 lines
610 B
Bash
#!/bin/bash
|
|
|
|
set -e
|
|
|
|
cd "$(dirname "$0")/.."
|
|
|
|
|
|
# Clone desktop/desktop and check out a known sha
|
|
repo=examples/desktop
|
|
|
|
if [ ! -d "$repo" ]; then
|
|
git clone https://github.com/desktop/desktop "$repo"
|
|
fi
|
|
|
|
pushd "$repo" && git pull
|
|
git reset --hard d1324f56d02dd9afca5d2e9da545905a7d41d671
|
|
popd
|
|
|
|
# TODO: Fix known issues in known_failures.txt
|
|
known_failures=$(cat script/known_failures.txt)
|
|
examples_to_parse=$(
|
|
for example in $(find "$repo" -name '*.ts'); do
|
|
if [[ ! $known_failures == *$example* ]]; then
|
|
echo $example
|
|
fi
|
|
done
|
|
)
|
|
|
|
echo $examples_to_parse | xargs -n 5000 tree-sitter parse -q
|