eolas/_scripts/random_revision_topic.sh

18 lines
360 B
Bash
Raw Normal View History

2022-12-11 19:00:05 +00:00
#!/bin/bash
2022-12-12 19:00:06 +00:00
DIRS_TO_PARSE="../Algorithms ../Computer_Architecture ../Databases"
for ele in $DIRS_TO_PARSE; do
2022-12-12 19:30:06 +00:00
MATCHES+=( $(find $ele -name "*.md" -type f) )
2022-12-12 19:00:06 +00:00
done
2022-12-12 19:30:06 +00:00
for i in ${MATCHES[@]}
do
echo $i
done
2022-12-12 19:00:06 +00:00
2022-12-12 19:30:06 +00:00
# Next steps:
# - Generate random number
# - Specify the range of the random number from 0 to length of $MATCHES
# - Return that index