mirror of
https://gitlab.com/upRootNutrition/website.git
synced 2025-06-16 04:25:11 -05:00
feat: added argument templates
This commit is contained in:
parent
36bedf1c09
commit
f2647072fb
25 changed files with 1136 additions and 4 deletions
19
frontend/scripts/directoryconverter.sh
Executable file
19
frontend/scripts/directoryconverter.sh
Executable file
|
@ -0,0 +1,19 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
for file in *; do
|
||||
# Check if it's a file (not a directory)
|
||||
if [ -f "$file" ]; then
|
||||
# Get filename without extension
|
||||
dirname="${file%.*}"
|
||||
|
||||
# Create directory if it doesn't exist
|
||||
if [ ! -d "$dirname" ]; then
|
||||
mkdir "$dirname"
|
||||
echo "Created directory: $dirname"
|
||||
fi
|
||||
|
||||
# Move the file into its directory
|
||||
mv "$file" "$dirname/"
|
||||
echo "Moved $file to $dirname/"
|
||||
fi
|
||||
done
|
Loading…
Add table
Add a link
Reference in a new issue