Skip to content

Instantly share code, notes, and snippets.

@gali8
Created December 6, 2017 16:52
Show Gist options
  • Save gali8/4549cff83c65e8d39fa972f0d727ec3c to your computer and use it in GitHub Desktop.
Save gali8/4549cff83c65e8d39fa972f0d727ec3c to your computer and use it in GitHub Desktop.
#to print Build settings type on terminal: xcodebuild -project MyProject.xcodeproj -target "MyTarget" -showBuildSettings
#PROJECT_DIR = /Users/daniele/Desktop/MyProjectFolder
project_content_folder="MyProject"
storyboard_file="Main.storyboard"
storyboard_file_orig="Main_orig.storyboard"
storyboard_file_backup="Main_bk.storyboard"
storyboard_dir="${PROJECT_DIR}/${project_content_folder}/Base.lproj"
echo ${storyboard_dir}
cd ${storyboard_dir}
if [ -f ${storyboard_file_backup} ]
then
cp ${storyboard_file_backup} ${storyboard_file}
#if [ -f ${storyboard_file} ]
#then
# rm -f ${storyboard_file_backup}
#fi
fi
if [ -f ${storyboard_file_orig} ]
then
rm -f ${storyboard_file_orig}
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment