Skip to content

Commit

Permalink
remove trailing space and extra line breaks
Browse files Browse the repository at this point in the history
  • Loading branch information
dericed committed Oct 23, 2017
1 parent 672abca commit 4c35508
Show file tree
Hide file tree
Showing 19 changed files with 16 additions and 36 deletions.
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,6 @@ if editing in the terminal, use this option to leave the configuration file edit

***


## Database Instructions

Media Microservices can be integrated with a database for the capture of a variety of preservation metadata generated through the mm workflow. Currently the MM Database supports PREMIS event information, fixity information, perceptual hashes for video files, mediainfo output and ingest logs.
Expand Down Expand Up @@ -312,7 +311,6 @@ To view the specific ffmpeg encoding options for each file, view the sourcecode
* if you would like to create an AIP but not have the file delivered to the omneon server or any of the access copies delivered, you can use option -n. Your command will look like: `ingestfile -n [file]`.
* if you would like to only deliver the AIP to the omneon server and AIP storage, you can use -i. Your command will look like: `ingestfile -i [file]`.


* here's two gifs of ingestfile
<img src="https://github.com/mediamicroservices/mm/blob/master/Resources/ingestfile.gif" width="500">
<img src="https://github.com/mediamicroservices/mm/blob/master/Resources/ingestfilegui.gif" width="500">
Expand Down
3 changes: 0 additions & 3 deletions Resources/dbinfo.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ Mediamicroservices includes a script for database backup. This can be either ru

To configure database backup use the command `dbbackup -e`. This will open the config file in a terminal editor. Set the neccessary variables to your desired values.


## Database structure
The Database is divided into six tables with the following structure:

Expand Down Expand Up @@ -89,8 +88,6 @@ Searches the LTO schema information stored in the database. Input for standard s

Usage: searchlto [-h] (help) [-c] (compares an input file to file information stored in DB) [-f] (shows full schema) [Input]



#### searchfingerprint

Generates fingerprints (perceptual hashes) from whole or specified portion of an input video file and compares them against fingerprints stored in the database. Outputs any detected matches in 500 frame segments both in the terminal and in an optional preview window. Preview window will attempt to locate the portions of input video for which matches were found.
Expand Down
3 changes: 1 addition & 2 deletions checksumpackage
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ while [ "${*}" != "" ] ; do
_report_to_db
echo "$(_get_iso8601): $(basename "${0}"):${VERSION}: ${CHECKSUMNAME} is generated" >> "${PACKAGE}/${OUTDIR}/${CHECKSUMPROCESSLOG}"
event_outcome="Fixity Creation"

if [ "${UPDATE}" = "Y" ] ; then
exit
fi
Expand Down Expand Up @@ -225,7 +225,6 @@ while [ "${*}" != "" ] ; do
echo "$(_get_iso8601): $(basename "${0}"):${VERSION}: verified by checksums" >> "${PACKAGE}/${OUTDIR}/${CHECKSUMPROCESSLOG}"
event_outcome="Fixity Match"
fi

rm "${CHECKSUMCMP1}" "${CHECKSUMCMP2}"
fi
#if [ "$FILEMAKER_XML_URL" ] ; then
Expand Down
4 changes: 1 addition & 3 deletions dbbackup
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,13 @@ while getopts "hec" opt ; do
esac
done


FILES=$(ls -rt "$SQL_BACKUP_DIR"/"$DATABASE_NAME"_backup_*.sql.gz)
FILE_COUNT=$(echo "$FILES" | wc -l)
OLDEST_FILE=$(echo "$FILES" | head -n 1)
BACKUP_FILE=${SQL_BACKUP_DIR}/"$DATABASE_NAME"_backup_`date +"%m-%d-%Y_%H-%M-%S"`.sql


if [ "$FILE_COUNT" -ge "$COPIES_NUMBER" ] ; then
rm "$OLDEST_FILE"
rm "$OLDEST_FILE"
fi

mysqldump --login-path="$SQL_LOGIN_PATH" "$DATABASE_NAME" > "$BACKUP_FILE"
Expand Down
1 change: 0 additions & 1 deletion ingestfile
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ fi
[ -z "${PODCASTDELIVER}" ] && { echo "A directory for podcast delivery must be set. Use [ -w /path/to/deliver/podcastfiles] or run mmconfig to set PODCASTDELIVER." ; exit 1 ;};
[ -z "${YOUTUBEDELIVER}" ] && { echo "A directory for youtube delivery must be set. Use [ -y /path/to/deliver/youtubefiles] or run mmconfig to set YOUTUBEDELIVER." ; exit 1 ;};


#pashua interface settings
CONF="
# Set transparency: 0 is transparent, 1 is opaque
Expand Down
12 changes: 6 additions & 6 deletions makederiv
Original file line number Diff line number Diff line change
Expand Up @@ -122,15 +122,15 @@ while [[ "${@}" != "" ]] ; do
SUFFIX="_PODCAST"
fi
_report_to_db

_set_up_output
if [[ "${OUTPUT_TYPE}" == "dvd" ]] || [[ "${OUTPUT_TYPE}" == "broadcast" ]] ; then
INPUTOPTIONS+=(-y)
elif [[ "${OUTPUT_TYPE}" != "mp3" ]] && [[ "${OUTPUT_TYPE}" != "podcast" ]] ; then
INPUTOPTIONS+=(-vsync 0)
fi
INPUTOPTIONS+=(-nostdin)

# get information on the input
_get_height "${SOURCEFILE}"
_get_width "${SOURCEFILE}"
Expand All @@ -140,7 +140,7 @@ while [[ "${@}" != "" ]] ; do
_get_audiostreamcount "${SOURCEFILE}"
_get_dar "${SOURCEFILE}"
_get_sar "${SOURCEFILE}"

# set in and out times if used; ignore out time if a slate is being created
if [[ -f "${INGESTLOG}" && "${ISOBJECT}" = "Y" ]] ; then
INTIME=$(_readingestlog "intime")
Expand All @@ -157,7 +157,7 @@ while [[ "${@}" != "" ]] ; do
MIDDLEOPTIONS+=(-to "${OUTTIME}")
fi
fi

# encoding options
if [[ "${VIDEOSTREAMCOUNT}" -gt 0 ]] ; then
if [[ "${CODEC_TAG_STRING}" == "mjp2" ]] ; then
Expand Down Expand Up @@ -511,7 +511,7 @@ while [[ "${@}" != "" ]] ; do
MIDDLEOPTIONS+=(-map "[with_slate_video]" -map "[with_slate_stereo1]" -map "[with_slate_mono1]" -map "[with_slate_mono2]")
fi
fi

# temporary output set for dvd to allow mpeg -> iso transition
if [[ "${OUTPUT_TYPE}" == "dvd" ]] ; then
OUTPUT_TMP="$OUTPUT"
Expand All @@ -533,7 +533,7 @@ while [[ "${@}" != "" ]] ; do
_run_critical_event mkisofs -f -dvd-video -udf -V "${volname:0:32}" -v -v -o "${OUTPUT}" "${OUTPUTDIR}/${MEDIAID%.*}" 2> "${LOGDIR}/mkisofs_$(_get_iso8601_c)_$(basename ${0})_${VERSION}.txt"
_run rm -r "${OUTPUTDIR}/${MEDIAID%.*}/"
fi

echo
_summarize_make
if [[ "${OUTPUT_TYPE}" == "broadcast" ]] && [[ -z "${MAKEBROADCAST_DELIVERY_EMAIL_TO}" ]] ; then
Expand Down
2 changes: 1 addition & 1 deletion makefingerprint
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ while [ "${*}" != "" ] ; do
SIGNATURE="${MEDIAID}""${SUFFIX}"."${EXTENSION}"
_run_critical_event ffmpeg "${FFMPEGINPUT[@]}" -vf signature=format=xml:filename="${FINGERDIR}/${SIGNATURE}" -map 0:v -f null -
FINGERPRINT_XML="${FINGERDIR}/${SIGNATURE}"

#Report to DB
if [ "${PERCEPTUAL_HASH}" = "1" ] && [ "${PREMIS_DB}" = "Y" ]; then
_fingerprint_to_db
Expand Down
2 changes: 0 additions & 2 deletions makeframemd5
Original file line number Diff line number Diff line change
Expand Up @@ -56,5 +56,3 @@ while [ "${*}" != "" ] ; do
done)
rm "${FILELIST}"
done


2 changes: 1 addition & 1 deletion makemkvchapters
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ while [ "${*}" != "" ] ; do
while [[ "${CHAPTER_NAME}" != 'q' && "${STARTTIME}" != 'q' && "${ENDTIME}" != 'q' && "${LINKEDSEGMENT}" != 'q' ]] ; do
_ask_for_chapter
done

_report "Start and end times must be in HH:MM:SS.mmm or S.mmm format. Note mmm is milliseconds and not frames."

echo "<?xml version='1.0' encoding='UTF-8'?>
Expand Down
4 changes: 2 additions & 2 deletions migratefiles
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ while [ "${*}" != "" ] ; do
_report_to_db
echo "The input is: ${INPUT}"
echo "The target is: ${TARGET}"

if [ "${INPUT}/" == "${TARGET}" ] ; then
echo "Due to the Target location and the Input location being the same, files will not be migrated."
exit 0
fi

shift
if [ -z "${LOGFILE}" ] ; then
LOGFILE="${HOME}/migrate.log"
Expand Down
3 changes: 0 additions & 3 deletions mmconfig
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,6 @@ MAKEYOUTUBE_DELIVERY_EMAIL_TO.label = Please enter the email account (or multipl
MAKEYOUTUBE_DELIVERY_EMAIL_TO.width = 125
MAKEYOUTUBE_DELIVERY_EMAIL_TO.default = ${MAKEYOUTUBE_DELIVERY_EMAIL_TO}
# MAKEBROADCAST_DELIVERY_EMAIL_TO
MAKEBROADCAST_DELIVERY_EMAIL_TO.x = 600
MAKEBROADCAST_DELIVERY_EMAIL_TO.y = 350
Expand Down Expand Up @@ -302,8 +301,6 @@ PERCEPTUAL_HASH.label = Generate video fingerprint?
PERCEPTUAL_HASH.tooltip = This will create perceptual fingerprints of the input video stream.
PERCEPTUAL_HASH.default = ${PERCEPTUAL_HASH}
# Add a cancel button with default label
cb.type=cancelbutton
Expand Down
2 changes: 1 addition & 1 deletion mmfunctions
Original file line number Diff line number Diff line change
Expand Up @@ -1443,7 +1443,7 @@ _prep_volume_adjustment(){
if [[ "${measured_I}" == "inf" ]] || [[ "${measured_I}" == "-inf" ]] ; then
VOLADJUST="N"
_report -wt "Integrated loudness for $(basename "${INPUT_MOVIE}") is ${measured_I} LUFS. Volume adjustment cannot be completed."
else
else
_report -dt "Integrated loudness for $(basename "${INPUT_MOVIE}") is ${measured_I} LUFS. Reference is -24 LUFS. Will adjust by ${LOUD_ADJ} LUFS"
_add_audio_filter "loudnorm=measured_I=${measured_I}:measured_LRA=${measured_LRA}:measured_TP=${measured_TP}:measured_thresh=${measured_thresh}:offset=${target_offset}:linear=true:print_format=summary"
fi
Expand Down
2 changes: 1 addition & 1 deletion mmtest
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ _checksumreport(){
else
_report -wt "Checksums do not match."
_report -w "Checksum expected: $EXPECTED_CHECKSUM"
_report -w "Checksum generated: $ACTUAL_CHECKSUM"
_report -w "Checksum generated: $ACTUAL_CHECKSUM"
FAILEDCHECKSUMS+="$OUTPUT_RELATIVE_PATH "
fi
}
Expand Down
1 change: 0 additions & 1 deletion phasecheck
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
SCRIPTDIR=$(dirname $(which "${0}"))
. "${SCRIPTDIR}/mmfunctions" || { echo "Missing '${SCRIPTDIR}/mmfunctions'. Exiting." ; exit 1 ;};


while [ "${*}" != "" ] ; do
INPUT="${1}"
shift
Expand Down
1 change: 0 additions & 1 deletion qatesting
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
SCRIPTDIR=$(dirname $(which "${0}"))
. "${SCRIPTDIR}/mmfunctions" || { echo "Missing '${SCRIPTDIR}/mmfunctions'. Exiting." ; exit 1 ;};


while [ "${*}" != "" ] ; do
INPUT="${1}"
shift
Expand Down
1 change: 0 additions & 1 deletion searchfingerprint
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ if ! [ "${1}" ] ; then
_usage
fi


while [ "${*}" != "" ] ; do
#Set up input and temp files
INPUT="${1}"
Expand Down
1 change: 0 additions & 1 deletion uploadomneon
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ while getopts ":h" OPT; do
done
shift $(( ${OPTIND} - 1 ))
if [ ! "${TMPDIR}" ] ; then
_report -wt "The temporary directory must be set and be available. Run 'mmconfig'."
exit 1
Expand Down
4 changes: 2 additions & 2 deletions verifytree
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ while [ "${*}" != "" ] ; do
#looks for any directories that are not access, service, or captions within the objects directory
_runtest "There are directories other than access and service in the objects directory!" xml sel -t -v "/tree/directory/directory[@name='objects']/directory[@name!='access' and @name!='service' and @name!='captions']/@name" -n "${TEMPTREE}"
#makes sure there is an object in the objects directory
_runtest -i "There isn't an object in the objects directory!" xml sel -t -v "/tree/directory/directory[@name='objects']/file[count(@name)>0]/@name" -n "${TEMPTREE}"
_runtest -i "There isn't an object in the objects directory!" xml sel -t -v "/tree/directory/directory[@name='objects']/file[count(@name)>0]/@name" -n "${TEMPTREE}"
#looks for any directories within access directory that are not dvd, images, mp3, podcast, or youtube_up
_runtest "There are unexpected directories in the access directory." xml sel -t -v "/tree/directory/directory[@name='objects']/directory[@name='access']/directory[@name!='dvd' and @name!='images' and @name!='mp3' and @name!='podcast' and @name!='youtube_up']/@name" -n "${TEMPTREE}"
#looks for unexpected files in youtube_up directory
Expand Down Expand Up @@ -129,7 +129,7 @@ while [ "${*}" != "" ] ; do

#makes sure no file names contain colons
_runtest "There are improperly named files in this package!" xml sel -t -v "//file[contains(@name,':')]/@name" -n "${TEMPTREE}"

#finds any hidden files
_runtest "There are hidden files in this package!" xml sel -t -v "//file[starts-with(@name,'.')]/@name" -n "${TEMPTREE}"
fi
Expand Down
2 changes: 0 additions & 2 deletions viruscheck
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,8 @@ SCRIPTDIR=$(dirname $(which "${0}"))
. "${SCRIPTDIR}/mmfunctions" || { echo "Missing '${SCRIPTDIR}/mmfunctions'. Exiting." ; exit 1 ;};
DEPENDENCIES=(clamav)


while [ "${*}" != "" ] ; do
INPUT="${1}"
shift

_run_critical clamscan -rva --log="${INPUT}/metadata/logs/clamav_$(date +%Y%m%d-%H%M%S).txt" "${INPUT}/objects"
done

0 comments on commit 4c35508

Please sign in to comment.