File: add-by-tag.sh

package info (click to toggle)
node-js-yaml 4.1.0%2Bdfsg%2B~4.0.5-7
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, sid, trixie
  • size: 11,112 kB
  • sloc: javascript: 20,148; makefile: 17; sh: 13
file content (18 lines) | stat: -rwxr-xr-x 375 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh

if test $# -eq 0; then
  echo "No branch/tag names provided"
  exit 1
fi

root_dir="$(dirname $0)"

for branch in $@; do
  impl_dir="$root_dir/implementations/js-yaml-$branch"

  if test -e "$impl_dir"; then
    echo "$impl_dir already exists; skipping"
  else
    git clone --branch "$branch" --depth 1 https://github.com/nodeca/js-yaml.git "$impl_dir"
  fi
done