mirror of
				https://github.com/KrumpetPirate/AAXtoMP3.git
				synced 2025-11-03 20:40:43 +01:00 
			
		
		
		
	fix indentation
This commit is contained in:
		
							
								
								
									
										18
									
								
								AAXtoMP3
									
									
									
									
									
								
							
							
						
						
									
										18
									
								
								AAXtoMP3
									
									
									
									
									
								
							@@ -19,7 +19,7 @@ DEBUG=0                     # Default off, If set extremely verbose output.
 | 
				
			|||||||
noclobber=0                 # Default off, clobber only if flag is enabled
 | 
					noclobber=0                 # Default off, clobber only if flag is enabled
 | 
				
			||||||
continue=0                  # Default off, If set Transcoding is skipped and chapter splitting starts at chapter continueAt.
 | 
					continue=0                  # Default off, If set Transcoding is skipped and chapter splitting starts at chapter continueAt.
 | 
				
			||||||
continueAt=1                # Optional chapter to continue splitting the chapters.
 | 
					continueAt=1                # Optional chapter to continue splitting the chapters.
 | 
				
			||||||
appendNarrator=0						# Default off, Append the narrator name to the Folder name. Needs mediainfo
 | 
					appendNarrator=0            # Default off, Append the narrator name to the Folder name. Needs mediainfo
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# -----
 | 
					# -----
 | 
				
			||||||
# Code tip Do not have any script above this point that calls a function or a binary.  If you do
 | 
					# Code tip Do not have any script above this point that calls a function or a binary.  If you do
 | 
				
			||||||
@@ -60,8 +60,8 @@ while true; do
 | 
				
			|||||||
    --continue        ) continueAt="$2"; continue=1;                                    shift 2 ;;
 | 
					    --continue        ) continueAt="$2"; continue=1;                                    shift 2 ;;
 | 
				
			||||||
                      # Compression level
 | 
					                      # Compression level
 | 
				
			||||||
    --level           ) level="$2";                                                     shift 2 ;;
 | 
					    --level           ) level="$2";                                                     shift 2 ;;
 | 
				
			||||||
											# Append Narrator
 | 
					                      # Append Narrator
 | 
				
			||||||
		--append-narrator	)	appendNarrator=1;																								shift ;;
 | 
					    --append-narrator ) appendNarrator=1;                                               shift ;;
 | 
				
			||||||
                      # Command synopsis.
 | 
					                      # Command synopsis.
 | 
				
			||||||
    -h | --help       ) printf "$usage" $0 ;                                            exit ;;
 | 
					    -h | --help       ) printf "$usage" $0 ;                                            exit ;;
 | 
				
			||||||
                      # Standard flag signifying the end of command line processing.
 | 
					                      # Standard flag signifying the end of command line processing.
 | 
				
			||||||
@@ -300,7 +300,7 @@ fi
 | 
				
			|||||||
# -----
 | 
					# -----
 | 
				
			||||||
# Check for presence of mediainfo in case the flag --append-narrator is used
 | 
					# Check for presence of mediainfo in case the flag --append-narrator is used
 | 
				
			||||||
if [[ "${appendNarrator}" == 1 && "x$(type -P mediainfo)" == "x" ]]; then
 | 
					if [[ "${appendNarrator}" == 1 && "x$(type -P mediainfo)" == "x" ]]; then
 | 
				
			||||||
	echo "ERROR --append-narator specified, but mediainfo is not in PATH"
 | 
					  echo "ERROR --append-narator specified, but mediainfo is not in PATH"
 | 
				
			||||||
  exit 1
 | 
					  exit 1
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -444,11 +444,11 @@ do
 | 
				
			|||||||
    description=""
 | 
					    description=""
 | 
				
			||||||
    publisher=""
 | 
					    publisher=""
 | 
				
			||||||
  fi
 | 
					  fi
 | 
				
			||||||
	# If the flag --append-narrator is used, we append the narrator name to the output dir
 | 
					  # If the flag --append-narrator is used, we append the narrator name to the output dir
 | 
				
			||||||
	if [[ "${appendNarrator}" == 1 ]]; then
 | 
					  if [[ "${appendNarrator}" == 1 ]]; then
 | 
				
			||||||
		output_directory="${output_directory}"-"${narrator}"
 | 
					    output_directory="${output_directory}"-"${narrator}"
 | 
				
			||||||
  	output_file="${output_directory}/${title}.${extension}"
 | 
					    output_file="${output_directory}/${title}.${extension}"
 | 
				
			||||||
	fi
 | 
					  fi
 | 
				
			||||||
  if [[ "${noclobber}" = "1" ]] && [[ -d "${output_directory}" ]]; then
 | 
					  if [[ "${noclobber}" = "1" ]] && [[ -d "${output_directory}" ]]; then
 | 
				
			||||||
    log "Noclobber enabled but directory '${output_directory}' exists. Exiting to avoid overwriting"
 | 
					    log "Noclobber enabled but directory '${output_directory}' exists. Exiting to avoid overwriting"
 | 
				
			||||||
    exit 0
 | 
					    exit 0
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -51,7 +51,7 @@ bash AAXtoMP3 [-f|--flac] [-o|--opus] [-a|-aac] [-s|--single] [--level <COMPRESS
 | 
				
			|||||||
* **-c** or **--chaptered** Output a single file per chapter. The `--chaptered` will only work if it follows the `--aac -e:m4a -e:m4b --flac` options.
 | 
					* **-c** or **--chaptered** Output a single file per chapter. The `--chaptered` will only work if it follows the `--aac -e:m4a -e:m4b --flac` options.
 | 
				
			||||||
* **--continue <CHAPTERNUMBER>**      If the splitting into chapters gets interrupted (e.g. by a weak battery on your laptop) you can go on where the process got interrupted. Just delete the last chapter (which was incompletely generated) and redo the task with "--continue <CHAPTERNUMBER>" where CHAPTERNUMBER is the chapter that got interrupted.
 | 
					* **--continue <CHAPTERNUMBER>**      If the splitting into chapters gets interrupted (e.g. by a weak battery on your laptop) you can go on where the process got interrupted. Just delete the last chapter (which was incompletely generated) and redo the task with "--continue <CHAPTERNUMBER>" where CHAPTERNUMBER is the chapter that got interrupted.
 | 
				
			||||||
* **--level <COMPRESSIONLEVEL>**      Set compression level. May be given for mp3, flac and opus.
 | 
					* **--level <COMPRESSIONLEVEL>**      Set compression level. May be given for mp3, flac and opus.
 | 
				
			||||||
* **--append-narrator**			Append narrator name to the destination folder, useful if you have multiple version of a book. Requires mediainfo.
 | 
					* **--append-narrator**     Append narrator name to the destination folder, useful if you have multiple version of a book. Requires mediainfo.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
### [AUTHCODE]
 | 
					### [AUTHCODE]
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user