Skip to content

Instantly share code, notes, and snippets.

View Hucent's full-sized avatar

Hucent

View GitHub Profile
@Hucent
Hucent / update_build.sh
Created December 2, 2017 12:46
Update Build Number
buildNumber=$(/usr/libexec/PlistBuddy -c "Print :CFBundleVersion" "${PROJECT_DIR}/${INFOPLIST_FILE}")
todayday=`date +"%Y%m%d"`
bb=`echo $buildNumber|grep $todayday|wc -l`
if [ $bb = 0 ]
then
buildNumber="$todayday""001"
else
buildNumber=$(($buildNumber + 1))
fi
@Hucent
Hucent / bartycrouch.sh
Created December 2, 2017 12:48
bartycrouch i18n
if which bartycrouch > /dev/null; then
# Incrementally update all Storyboards/XIBs strings files
bartycrouch interfaces -p "$PROJECT_DIR"
# Add new keys to Localizable.strings files from NSLocalizedString in code
bartycrouch code -p "$PROJECT_DIR" -l "$PROJECT_DIR" -a
# Translate all empty values using the Microsoft Translator API
#bartycrouch translate -p "$PROJECT_DIR" -l en -i "<API_ID>" -s "<API_SECRET>"
@Hucent
Hucent / archive_ipa.py
Created December 2, 2017 12:57
Archive ipa
#coding:utf-8
import zipfile, plistlib, sys, re, datetime, os, shutil
def analyze_ipa_with_plistlib(ipa_path):
print ('path: %s' % ipa_path)
ipa_file = zipfile.ZipFile(ipa_path)
plist_path = find_plist_path(ipa_file)
plist_data = ipa_file.read(plist_path)
plist_root = plistlib.loads(plist_data)

Keybase proof

I hereby claim:

  • I am hucent on github.
  • I am hucent (https://keybase.io/hucent) on keybase.
  • I have a public key ASCa_oQanBpra1RoobyD4IKwLAUAaF38tk0RpWhR5nIrCgo

To claim this, I am signing this object:

Verify Github on Galaxy. gid:hRxVBHuzZGAUapoS87zoJc