Skip to content

Commit

Permalink
Merge pull request #2 from GalacticSage/Gundam-0080
Browse files Browse the repository at this point in the history
Gundam 0080
  • Loading branch information
GalacticSage committed Jun 6, 2024
2 parents d6b80e9 + e19b9d9 commit 789a1f1
Show file tree
Hide file tree
Showing 9 changed files with 119 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Fullmetal Alchemist Brotherhood/readme.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
These scripts are tailored for the "Fullmetal Alchemist Brotherhood - Gate Of Truth Box-Set" published by Dynit.
These scripts are tailored for "Fullmetal Alchemist Brotherhood - Gate Of Truth Box-Set" published by Dynit.
2 changes: 1 addition & 1 deletion Great Teacher Onizuka/readme.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
These scripts are tailored for the "GTO: Great Teacher Onizuka Serie Completa" published by Dynit.
These scripts are tailored for "GTO: Great Teacher Onizuka Serie Completa" published by Dynit.
4 changes: 4 additions & 0 deletions Gundam 0080/BD/all_disc.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/bash

./disc_1.sh
./disc_2.sh
47 changes: 47 additions & 0 deletions Gundam 0080/BD/disc_1.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
#!/bin/bash

input_file="source_rips/MOBILE SUITE GUNDAM 0080_disc1/MOBILE SUITE GUNDAM 0080_t00.mkv"

tmp_output_directory="tmp/disc1/"
output_directory="output/Gundam 0080/"
output_season_directory="${output_directory}s01/"

output_pattern="${tmp_output_directory}segment_%d.mkv"

oav1="Quante miglia per il campo di battaglia?"
oav2="Riflesso in occhi castani"
oav3="E alla fine dell'arcobaleno?"

# Function to create directory if it doesn't exist
create_directory() {
if [ ! -d "$1" ]; then
mkdir -p "$1"
echo "Directory '$1' created."
else
echo "Directory '$1' already exists."
fi
}

echo "Creating directories..."
create_directory "$tmp_output_directory"
create_directory "$output_directory"
create_directory "$output_season_directory"

echo "Unselecting forced flag for subtitles..."
mkvpropedit --edit track:7 --set flag-forced=1 "$input_file"

echo "Splitting input file based on chapters..."
mkvmerge -o "$output_pattern" --split chapters:7,12 "$input_file"

echo "Setting titles for segments..."
mkvpropedit "${tmp_output_directory}segment_1.mkv" --edit info --set "title=${oav1}"
mkvpropedit "${tmp_output_directory}segment_2.mkv" --edit info --set "title=${oav2}"
mkvpropedit "${tmp_output_directory}segment_3.mkv" --edit info --set "title=${oav3}"

echo "Moving and renaming files..."
mv "${tmp_output_directory}segment_1.mkv" "${output_season_directory}s01e01.mkv"
mv "${tmp_output_directory}segment_2.mkv" "${output_season_directory}s01e02.mkv"
mv "${tmp_output_directory}segment_3.mkv" "${output_season_directory}s01e03.mkv"

echo "Cleaning up temporary files..."
rm -rf tmp/
47 changes: 47 additions & 0 deletions Gundam 0080/BD/disc_2.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
#!/bin/bash

input_file="source_rips/MOBILE SUITE GUNDAM 0080_disc2/MOBILE SUITE GUNDAM 0080_t00.mkv"

tmp_output_directory="tmp/disc2/"
output_directory="output/Gundam 0080/"
output_season_directory="${output_directory}s01/"

output_pattern="${tmp_output_directory}segment_%d.mkv"

oav4="Oltre il fiume e tra gli alberi"
oav5="Dì che non è così, Bernie!"
oav6="La guerra in tasca"

# Function to create directory if it doesn't exist
create_directory() {
if [ ! -d "$1" ]; then
mkdir -p "$1"
echo "Directory '$1' created."
else
echo "Directory '$1' already exists."
fi
}

echo "Creating directories..."
create_directory "$tmp_output_directory"
create_directory "$output_directory"
create_directory "$output_season_directory"

echo "Unselecting forced flag for subtitles..."
mkvpropedit --edit track:7 --set flag-forced=1 "$input_file"

echo "Splitting input file based on chapters..."
mkvmerge -o "$output_pattern" --split chapters:6,11 "$input_file"

echo "Setting titles for segments..."
mkvpropedit "${tmp_output_directory}segment_1.mkv" --edit info --set "title=${oav4}"
mkvpropedit "${tmp_output_directory}segment_2.mkv" --edit info --set "title=${oav5}"
mkvpropedit "${tmp_output_directory}segment_3.mkv" --edit info --set "title=${oav6}"

echo "Moving and renaming files..."
mv "${tmp_output_directory}segment_1.mkv" "${output_season_directory}s01e04.mkv"
mv "${tmp_output_directory}segment_2.mkv" "${output_season_directory}s01e05.mkv"
mv "${tmp_output_directory}segment_3.mkv" "${output_season_directory}s01e06.mkv"

echo "Cleaning up temporary files..."
rm -rf tmp/
12 changes: 12 additions & 0 deletions Gundam 0080/BD/source_rips/readme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
To ensure the scripts function correctly, please place your video rips in the designated folders following the structure created by MakeMKV. Additionally, append the disc number at the end of each folder name, formatted like "_disc1". Here's an example of the directory layout using the 'ls -R' command:

.:
'MOBILE SUITE GUNDAM 0080_disc1'
'MOBILE SUITE GUNDAM 0080_disc2'
readme.txt

'./MOBILE SUITE GUNDAM 0080_disc1':
'MOBILE SUITE GUNDAM 0080_t00.mkv'

'./MOBILE SUITE GUNDAM 0080_disc2':
'MOBILE SUITE GUNDAM 0080_t00.mkv'
1 change: 1 addition & 0 deletions Gundam 0080/readme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
These scripts are tailored for "Mobile Suit Gundam 0080" published by Dynit.
3 changes: 3 additions & 0 deletions README.it.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ Date un'occhiata alla nostra lista attuale di uscite supportate qui sotto:
- **Progresso:** Supportati tutti i dischi (Disco 1, Disco 2, Disco 3, Disco 4, Disco 5, Disco 6, Disco 7 e Disco 8).
- **Extra:** Tutti gli OAV sono supportati (Disco 1, Disco 3, Disco 5 e Disco 7).

- **Gundam 0080 (BD):**
- **Progresso:** Supportati tutti i dischi (Disco 1 e Disco 2).

- **Great Teacher Onizuka (DVD):**
- **Progresso:** Supportati tutti i dischi (Disco 1, Disco 2, Disco 3, Disco 4, Disco 5 e Disco 6).
## Requisiti
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ Check out our current list of supported releases below:
- **Progress:** Supported all discs (Disc 1, Disc 2, Disc 3, Disc 4, Disc 5, Disc 6, Disc 7 & Disc 8).
- **Extras:** All OVAs supported (Disc 1, Disc 3, Disc 5 & Disc 7).

- **Gundam 0080 (BD):**
- **Progress:** Supported all discs (Disc 1 & Disc 2).

- **Great Teacher Onizuka (DVD):**
- **Progress:** Supported all discs (Disc 1, Disc 2, Disc 3, Disc 4, Disc 5 & Disc 6).

Expand Down

0 comments on commit 789a1f1

Please sign in to comment.