Datasets:

Modalities:
Text
Formats:
json
Languages:
English
Libraries:
Datasets
pandas
License:
json-schema / fetch_files.sh
michaelmior's picture
Initial commit with working fetch scripts
adad30d verified
raw
history blame
452 Bytes
#!/bin/bash
pv repos.csv | tail -n +2 | \
while IFS=, read -r repo stars fetched commit path; do
path=$(echo "$path" | tr -d '\r')
source=$(echo "$repo" | cut -d/ -f1)
if [ "$source" == "github.com" ]; then
repo_name=$(echo "$repo" | cut -d/ -f2-)
curl "https://raw.githubusercontent.com/$repo_name/$commit/$path" --silent --create-dirs -o "data/$repo/$path"
sleep 1
fi
done