diff --git a/.DS_Store b/.DS_Store deleted file mode 100644 index 12e4aa2..0000000 Binary files a/.DS_Store and /dev/null differ diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e21dedd --- /dev/null +++ b/.gitignore @@ -0,0 +1,30 @@ +# macOS +.DS_Store + +# Xcode / build artifacts +build/ +DerivedData/ +*.xcarchive +*.ipa +*.dSYM +*.dSYM.zip +*.xcuserstate +xcuserdata/ + +# Signing / credentials (no versionar) +*.mobileprovision +*.p8 +*.p12 +*.cer +ExportOptions.plist + +# fastlane generated +fastlane/report.xml +fastlane/README.md +fastlane/Preview.html +fastlane/test_output/ + +# Documentos personales / binarios que no son del proyecto +Justificante_*.pdf +*.pkg +og-image.png diff --git a/PortfolioJournal.xcodeproj/project.xcworkspace/xcuserdata/alexandrev.xcuserdatad/UserInterfaceState.xcuserstate b/PortfolioJournal.xcodeproj/project.xcworkspace/xcuserdata/alexandrev.xcuserdatad/UserInterfaceState.xcuserstate deleted file mode 100644 index caab3b9..0000000 Binary files a/PortfolioJournal.xcodeproj/project.xcworkspace/xcuserdata/alexandrev.xcuserdatad/UserInterfaceState.xcuserstate and /dev/null differ diff --git a/PortfolioJournal/.DS_Store b/PortfolioJournal/.DS_Store deleted file mode 100644 index 97a9bd9..0000000 Binary files a/PortfolioJournal/.DS_Store and /dev/null differ diff --git a/PortfolioJournal/Assets.xcassets/.DS_Store b/PortfolioJournal/Assets.xcassets/.DS_Store deleted file mode 100644 index 42828f7..0000000 Binary files a/PortfolioJournal/Assets.xcassets/.DS_Store and /dev/null differ diff --git a/PortfolioJournal/Resources/Info.plist b/PortfolioJournal/Resources/Info.plist index 5172472..180cadc 100644 --- a/PortfolioJournal/Resources/Info.plist +++ b/PortfolioJournal/Resources/Info.plist @@ -17,7 +17,7 @@ CFBundlePackageType APPL CFBundleShortVersionString - 1.4.1 + $(MARKETING_VERSION) CFBundleURLTypes @@ -30,7 +30,7 @@ CFBundleVersion - 42 + $(CURRENT_PROJECT_VERSION) GADApplicationIdentifier ca-app-pub-1549720748100858~9632507420 GADDelayAppMeasurementInit diff --git a/PortfolioJournalWidget/Info.plist b/PortfolioJournalWidget/Info.plist index fe50bad..32695ab 100644 --- a/PortfolioJournalWidget/Info.plist +++ b/PortfolioJournalWidget/Info.plist @@ -15,9 +15,9 @@ CFBundlePackageType $(PRODUCT_BUNDLE_PACKAGE_TYPE) CFBundleShortVersionString - 1.4.1 + $(MARKETING_VERSION) CFBundleVersion - 42 + $(CURRENT_PROJECT_VERSION) ITSAppUsesNonExemptEncryption NSExtension diff --git a/Scripts/archive_and_upload_appstore.sh b/Scripts/archive_and_upload_appstore.sh index fd6637c..f14be78 100755 --- a/Scripts/archive_and_upload_appstore.sh +++ b/Scripts/archive_and_upload_appstore.sh @@ -33,37 +33,41 @@ fail() { exit 1 } +# Resuelve la clave .p8 y la deja en la variable global P8_PATH. +# IMPORTANTE: NO llamar con $(find_p8_file). El fichero temporal extraído de pass se +# limpia con un `trap EXIT`; si la función corre dentro de un subshell de sustitución +# de comandos, ese trap se dispara al cerrarse el subshell y borra el .p8 ANTES del +# export (xcodebuild fallaba con "-authenticationKeyPath ... existing file"). find_p8_file() { # 1. Variable de entorno explícita if [[ -n "$P8_PATH" ]]; then [[ -f "$P8_PATH" ]] || fail "No existe el fichero APPSTORE_P8_PATH=$P8_PATH" - echo "$P8_PATH" return fi - # 2. Extraer de pass y escribir en fichero temporal + # 2. Extraer de pass y escribir en fichero temporal (limpieza al salir del script) if command -v pass >/dev/null 2>&1 && pass show appstore/api-key-p8 &>/dev/null; then local tmp_p8 tmp_p8="$(mktemp /tmp/AuthKey_XXXXXX.p8)" pass show appstore/api-key-p8 > "$tmp_p8" chmod 600 "$tmp_p8" - # Registrar para limpieza al salir + # Registrar para limpieza al salir del script (trap en el shell principal). trap "rm -f '$tmp_p8'" EXIT - echo "$tmp_p8" + P8_PATH="$tmp_p8" return fi # 3. Fichero por defecto en HOME local default_path="$HOME/AuthKey_${KEY_ID}.p8" if [[ -f "$default_path" ]]; then - echo "$default_path" + P8_PATH="$default_path" return fi # 4. Único .p8 en HOME local matches=("${HOME}"/*.p8(N)) if (( ${#matches[@]} == 1 )); then - echo "${matches[1]}" + P8_PATH="${matches[1]}" return fi @@ -143,7 +147,7 @@ main() { command -v xcodebuild >/dev/null 2>&1 || fail "xcodebuild no esta disponible" command -v xcrun >/dev/null 2>&1 || fail "xcrun no esta disponible" - P8_PATH="$(find_p8_file)" + find_p8_file # asigna P8_PATH; NO usar $(...) o el trap del subshell borra el .p8 P8_DIR="$(dirname "$P8_PATH")" echo "Usando proyecto: $PROJECT_PATH"