Skip to content

Commit

Permalink
fixed Update manifest pfm_last_modified and pfm_version #164
Browse files Browse the repository at this point in the history
  • Loading branch information
twocanoes committed Feb 13, 2024
1 parent fbc40e4 commit a9f5ccc
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 331 deletions.
6 changes: 3 additions & 3 deletions Profile Manifest/com.twocanoes.xcreds.plist
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
<key>pfm_app_url</key>
<string>https://github.com/twocanoes/xcreds</string>
<key>pfm_description</key>
<string>XCreds 4.1 (6324) OAuth Settings</string>
<string>XCreds 4.1 (6342) OAuth Settings</string>
<key>pfm_documentation_url</key>
<string>https://twocanoes.com/knowledge-base/xcreds-admin-guide/#preferences</string>
<key>pfm_domain</key>
<string>com.twocanoes.xcreds</string>
<key>pfm_format_version</key>
<integer>1</integer>
<key>pfm_last_modified</key>
<date>2023-10-16T16:50:44Z</date>
<date>2024-02-13T19:51:33Z</date>
<key>pfm_platforms</key>
<array>
<string>macOS</string>
Expand Down Expand Up @@ -1275,6 +1275,6 @@ changing “passwordID” to the correct element ID. If the value you typed into
<key>pfm_unique</key>
<false/>
<key>pfm_version</key>
<integer>5</integer>
<integer>6</integer>
</dict>
</plist>
13 changes: 11 additions & 2 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,19 @@ set -e
echo "post to github? (y/N)"
read should_upload
if [ "${should_upload}" = "y" ]; then
upload=1
echo "uploading to github when done"
export upload=1
echo "uploading to github when done"
fi


echo "updated manifest version? (y/N)"
read should_update_manifest
if [ "${should_update_manifest}" = "y" ]; then
export update_manifest=1
echo "updating manifest"
fi


carthage update
xcodebuild -resolvePackageDependencies

Expand Down
14 changes: 12 additions & 2 deletions build_resources/buildscripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ PRODUCT_NAME="XCreds"
SCRIPT_FOLDER="$(dirname $0)"
PROJECT_FOLDER="../../"
SRC_PATH="../../"

echo manifest: $update_manifest
echo upload: $upload
###########################

if [ -e "${SRC_PATH}/../build/bitbucket_creds.sh" ] ; then
Expand All @@ -23,10 +24,19 @@ popd

marketing_version=$(sed -n '/MARKETING_VERSION/{s/MARKETING_VERSION = //;s/;//;s/^[[:space:]]*//;p;q;}' "${PROJECT_FOLDER}"/XCreds.xcodeproj/project.pbxproj)

#/usr/libexec/PlistBuddy -c "Set :pfm_version ${buildNumber}" "${PROJECT_FOLDER}/Profile Manifest/com.twocanoes.xcreds.plist"
date=$(date)


/usr/libexec/PlistBuddy -c "Set :pfm_last_modified \"${date}\"" "${PROJECT_FOLDER}/Profile Manifest/com.twocanoes.xcreds.plist"
/usr/libexec/PlistBuddy -c "Set :pfm_description \"XCreds ${marketing_version} (${buildNumber}) OAuth Settings\"" "${PROJECT_FOLDER}/Profile Manifest/com.twocanoes.xcreds.plist"

if [ -n "${update_manifest}" ]; then
echo "getting current manifest version"
curr_vers=$(/usr/libexec/PlistBuddy -c "Print :pfm_version" "${PROJECT_FOLDER}/Profile Manifest/com.twocanoes.xcreds.plist")
curr_vers=$((${curr_vers}+1))
echo "setting version to : ${curr_vers}"
/usr/libexec/PlistBuddy -c "Set :pfm_version ${curr_vers}" "${PROJECT_FOLDER}/Profile Manifest/com.twocanoes.xcreds.plist"
fi

temp_folder=$(mktemp -d "/tmp/${PRODUCT_NAME}.XXXXXXXX")
BUILD_FOLDER="${temp_folder}/build"
Expand Down
12 changes: 6 additions & 6 deletions xCreds.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1440,7 +1440,7 @@
buildSettings = {
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6324;
CURRENT_PROJECT_VERSION = 6342;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = UXP6YEHSPW;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1477,7 +1477,7 @@
buildSettings = {
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6324;
CURRENT_PROJECT_VERSION = 6342;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = UXP6YEHSPW;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1598,7 +1598,7 @@
CODE_SIGN_ENTITLEMENTS = "XCreds Login Overlay/XCreds_Login_Overlay.entitlements";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6324;
CURRENT_PROJECT_VERSION = 6342;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1635,7 +1635,7 @@
CODE_SIGN_ENTITLEMENTS = "XCreds Login Overlay/XCreds_Login_Overlay.entitlements";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6324;
CURRENT_PROJECT_VERSION = 6342;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1785,7 +1785,7 @@
CODE_SIGN_ENTITLEMENTS = XCreds/xCreds.entitlements;
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6324;
CURRENT_PROJECT_VERSION = 6342;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1827,7 +1827,7 @@
CODE_SIGN_ENTITLEMENTS = XCreds/xCreds.entitlements;
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6324;
CURRENT_PROJECT_VERSION = 6342;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down
Binary file not shown.
Loading

0 comments on commit a9f5ccc

Please sign in to comment.