-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ローカル開発用のbuild_restart.sh
とCONTRIBUTING.md
を設置
#143
Conversation
ありがとうございます。作者の手元ではこんなスクリプトをもってました。みんな考えることは同じですね。 #!/bin/sh -eux
# デバッグビルドと置き替えてmacSKKを再起動するスクリプト
# 実行にはtrashコマンド, jqコマンドが必要です。
# https://github.com/ali-rantakari/trash
# https://jqlang.github.io/jq/
debug_path=$(xcodebuild -showBuildSettings -json -project macSKK.xcodeproj -scheme macSKK -configuration Debug 2>/dev/null | jq --raw-output '.[0].buildSettings | [.CONFIGURATION_BUILD_DIR, .WRAPPER_NAME] | join("/")')
# インストールされているmacSKKを移動
path="$HOME/Library/Input Methods/macSKK.app"
if [ -d "$path" ]; then
mv "$path" /tmp
fi
# DebugビルドをInput Methodsに移動
if [ -d "$debug_path" ]; then
cp -r "$debug_path" "$HOME/Library/Input Methods/"
fi
# 起動中のmacSKKを全部終了する
osascript -e 'tell application id "net.mtgto.inputmethod.macSKK" to quit' || true
if [ -d "/tmp/macSKK.app" ]; then
trash "/tmp/macSKK.app"
fi
open "$path" |
そういえばmacOS 14+でApp Sandboxのセキュリティが強化されて、リリースページで配布されているバイナリに使っているCertificateと異なるチーム Provisioning Profileを使うと 貢献者が手元で私のTeam IDのProvisioning Profileをもたずにデバッグ実行するにはリリース版macSKKとはBundle Identifierが異なるバイナリを作れるようにしたほうがいいのかなあ…? とか考えていたりしました。 |
あまりちゃんとわかってないですが、こういう 👇編集をしないと手元でコンパイルできないですね。 diff --git a/macSKK.xcodeproj/project.pbxproj b/macSKK.xcodeproj/project.pbxproj
index 9434232..1a2e0a8 100644
--- a/macSKK.xcodeproj/project.pbxproj
+++ b/macSKK.xcodeproj/project.pbxproj
@@ -840,7 +840,7 @@
CURRENT_PROJECT_VERSION = 32;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_ASSET_PATHS = "\"macSKK/Preview Content\"";
- DEVELOPMENT_TEAM = W3A6B7FDC7;
+ DEVELOPMENT_TEAM = "";
ENABLE_HARDENED_RUNTIME = NO;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
@@ -876,7 +876,7 @@
CURRENT_PROJECT_VERSION = 32;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_ASSET_PATHS = "\"macSKK/Preview Content\"";
- DEVELOPMENT_TEAM = W3A6B7FDC7;
+ DEVELOPMENT_TEAM = "";
ENABLE_HARDENED_RUNTIME = YES;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
@@ -941,7 +941,7 @@
CODE_SIGN_ENTITLEMENTS = FetchUpdateService/FetchUpdateService.entitlements;
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
- DEVELOPMENT_TEAM = W3A6B7FDC7;
+ DEVELOPMENT_TEAM = "";
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = FetchUpdateService/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = FetchUpdateService; |
どうしようかな、このスクリプトじゃなくてもいいんですが、この手のものが何かしらないと普通の人(?)にとってはローカルでの検証が難しそうなので、なにかしらあったほうがいい気はしますね 👀 |
これは私がApple Develop Program (有償) に入ってAppleからもらっているTeam IDなのでたしかに変更しないとビルド通らなくなりますね (コンパイル後に署名する際に使ってる)。 #60 でやめたんですが、xcodebuildの引数で OSS開発でコラボレーターに共通のTeam IDを使って開発する、ってできないのかなあ… |
Apple Developer契約したユーザー (Developer Program契約はせず、無料でもよいはず) をDeveloperとして私のTeamに追加、macSKKのMacアプリ開発用Provisioning Profileにコラボレーターの証明書とコラボレーターの端末を追加することはできる… 気がする。 |
Co-authored-by: Satoshi Goto <[email protected]>
自分はApple Develop Programに毎年お金を払ってるんですが、理想的にはお金を払っていない方でも簡単な操作(環境変数の設定など?)で |
|
|
||
set -e | ||
# ビルド | ||
xcodebuild -workspace macSKK.xcodeproj/project.xcworkspace -scheme macSKK DEVELOPMENT_TEAM= clean archive -archivePath build/archive.xcarchive |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#60 を参考に DEVELOPMENT_TEAM=
を追加した。
CONTRIBUTING.md
を設置した