Rafael Calleja commited on
Commit
8932891
·
1 Parent(s): af85b1b

create generator

Browse files
data/squash/{releases/download/rafaelcalleja/distrostore/ubuntu-24.04 → ubuntu/24.04/GNOME}/filesystem.squashfs RENAMED
File without changes
data/squash/{releases/download/rafaelcalleja/distrostore/ubuntu-24.04 → ubuntu/24.04/GNOME}/initrd RENAMED
File without changes
data/squash/{releases/download/rafaelcalleja/distrostore/ubuntu-24.04 → ubuntu/24.04/GNOME}/vmlinuz RENAMED
File without changes
scripts/build.sh ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+
3
+ # Function to create the structure
4
+ generate_structure() {
5
+ local dir_path=$1
6
+ local base_name=$(basename "$(dirname "$(dirname "$dir_path")")")
7
+ local version=$(basename "$(dirname "$dir_path")")
8
+ local flavor=$(basename "$dir_path")
9
+
10
+ # Defining the structure
11
+ echo " ${base_name}-${version}-${flavor}-custom:"
12
+ echo " path: ${dir_path#/data}"
13
+ echo " files:"
14
+
15
+ # Listing files in the directory
16
+ for file in "$dir_path"/*; do
17
+ echo " - $(basename "$file")"
18
+ done
19
+
20
+ echo " os: ${base_name}-custom"
21
+ echo " version: '$version'"
22
+ echo " flavor: $flavor"
23
+ echo " kernel: ${base_name}-${version}-${flavor}-custom"
24
+ echo ""
25
+ }
26
+
27
+ # Iterating over the directories inside 'data'
28
+ find ./data -mindepth 4 -maxdepth 4 -type d | while read -r dir; do
29
+ generate_structure "$dir"
30
+ done
31
+