Misc Tweaks + Add Git Submodule
This commit is contained in:
parent
3ee3fed45e
commit
67fdecf807
|
@ -6,15 +6,10 @@ jobs:
|
||||||
name: Build
|
name: Build
|
||||||
runs-on: macOS-latest
|
runs-on: macOS-latest
|
||||||
env:
|
env:
|
||||||
DEVELOPER_DIR: /Applications/Xcode_12.app/Contents/Developer
|
DEVELOPER_DIR: /Applications/Xcode_13.2.app/Contents/Developer
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v1
|
||||||
- name: Clean
|
- name: Clean
|
||||||
run: xcodebuild -scheme McBopomofo -configuration Release clean
|
run: make clean
|
||||||
- name: Clean
|
|
||||||
run: xcodebuild -scheme McBopomofoInstaller -configuration Release clean
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: xcodebuild -scheme McBopomofo -configuration Release build
|
run: git pull --all && git submodule sync; make update; make
|
||||||
- name: Build
|
|
||||||
run: xcodebuild -scheme McBopomofoInstaller -configuration Release build
|
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
[submodule "Source/Data"]
|
||||||
|
path = Source/Data
|
||||||
|
url = https://gitee.com/vchewing/libvchewing-data
|
|
@ -0,0 +1,41 @@
|
||||||
|
+.PHONY: all
|
||||||
|
|
||||||
|
all: release
|
||||||
|
install: install-release
|
||||||
|
update:
|
||||||
|
@git restore Source/Data/
|
||||||
|
git submodule update --init --recursive --remote --force
|
||||||
|
|
||||||
|
ifdef ARCHS
|
||||||
|
BUILD_SETTINGS += ARCHS="$(ARCHS)"
|
||||||
|
BUILD_SETTINGS += ONLY_ACTIVE_ARCH=NO
|
||||||
|
endif
|
||||||
|
|
||||||
|
release:
|
||||||
|
xcodebuild -project McBopomofo.xcodeproj -scheme McBopomofoInstaller -configuration Release $(BUILD_SETTINGS) build
|
||||||
|
|
||||||
|
debug:
|
||||||
|
xcodebuild -project McBopomofo.xcodeproj -scheme McBopomofoInstaller -configuration Debug $(BUILD_SETTINGS) build
|
||||||
|
|
||||||
|
DSTROOT = /Library/Input Methods
|
||||||
|
VC_APP_ROOT = $(DSTROOT)/McBopomofo.app
|
||||||
|
|
||||||
|
.PHONY: permission-check install-debug install-release
|
||||||
|
|
||||||
|
permission-check:
|
||||||
|
[ -w "$(DSTROOT)" ] && [ -w "$(VC_APP_ROOT)" ] || sudo chown -R ${USER} "$(DSTROOT)"
|
||||||
|
|
||||||
|
install-debug: permission-check
|
||||||
|
rm -rf "$(VC_APP_ROOT)"
|
||||||
|
open Build/Products/Debug/McBopomofoInstaller.app
|
||||||
|
|
||||||
|
install-release: permission-check
|
||||||
|
rm -rf "$(VC_APP_ROOT)"
|
||||||
|
open Build/Products/Release/McBopomofoInstaller.app
|
||||||
|
|
||||||
|
.PHONY: clean
|
||||||
|
|
||||||
|
clean:
|
||||||
|
xcodebuild -scheme McBopomofoInstaller -configuration Debug $(BUILD_SETTINGS) clean
|
||||||
|
xcodebuild -scheme McBopomofoInstaller -configuration Release $(BUILD_SETTINGS) clean
|
||||||
|
make clean --file=./Source/Data/Makefile || true
|
|
@ -50,6 +50,7 @@
|
||||||
6AFF97F3253B299E007F1C49 /* OVNonModalAlertWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 6AFF97F1253B299E007F1C49 /* OVNonModalAlertWindowController.m */; };
|
6AFF97F3253B299E007F1C49 /* OVNonModalAlertWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 6AFF97F1253B299E007F1C49 /* OVNonModalAlertWindowController.m */; };
|
||||||
D427A9C125ED28CC005D43E0 /* OpenCCBridge.swift in Sources */ = {isa = PBXBuildFile; fileRef = D427A9C025ED28CC005D43E0 /* OpenCCBridge.swift */; };
|
D427A9C125ED28CC005D43E0 /* OpenCCBridge.swift in Sources */ = {isa = PBXBuildFile; fileRef = D427A9C025ED28CC005D43E0 /* OpenCCBridge.swift */; };
|
||||||
D48550A325EBE689006A204C /* OpenCC in Frameworks */ = {isa = PBXBuildFile; productRef = D48550A225EBE689006A204C /* OpenCC */; };
|
D48550A325EBE689006A204C /* OpenCC in Frameworks */ = {isa = PBXBuildFile; productRef = D48550A225EBE689006A204C /* OpenCC */; };
|
||||||
|
|
||||||
/* End PBXBuildFile section */
|
/* End PBXBuildFile section */
|
||||||
|
|
||||||
/* Begin PBXContainerItemProxy section */
|
/* Begin PBXContainerItemProxy section */
|
||||||
|
@ -190,7 +191,7 @@
|
||||||
6A38BBFB15FC117A00A8A51F /* phrase.occ */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = phrase.occ; sourceTree = "<group>"; };
|
6A38BBFB15FC117A00A8A51F /* phrase.occ */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = phrase.occ; sourceTree = "<group>"; };
|
||||||
6A38BBFC15FC117A00A8A51F /* PhraseFreq.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = PhraseFreq.txt; sourceTree = "<group>"; };
|
6A38BBFC15FC117A00A8A51F /* PhraseFreq.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = PhraseFreq.txt; sourceTree = "<group>"; };
|
||||||
6A38BBFD15FC117A00A8A51F /* README */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = README; sourceTree = "<group>"; };
|
6A38BBFD15FC117A00A8A51F /* README */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = README; sourceTree = "<group>"; };
|
||||||
6A38BC2715FC158A00A8A51F /* InputMethodKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = InputMethodKit.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/InputMethodKit.framework; sourceTree = DEVELOPER_DIR; };
|
6A38BC2715FC158A00A8A51F /* InputMethodKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = InputMethodKit.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/InputMethodKit.framework; sourceTree = DEVELOPER_DIR; };
|
||||||
6ACA41CB15FC1D7500935EF6 /* McBopomofoInstaller.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = McBopomofoInstaller.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
6ACA41CB15FC1D7500935EF6 /* McBopomofoInstaller.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = McBopomofoInstaller.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||||
6ACA41E815FC1D9000935EF6 /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = Source/Installer/AppDelegate.h; sourceTree = SOURCE_ROOT; };
|
6ACA41E815FC1D9000935EF6 /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = Source/Installer/AppDelegate.h; sourceTree = SOURCE_ROOT; };
|
||||||
6ACA41E915FC1D9000935EF6 /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = Source/Installer/AppDelegate.m; sourceTree = SOURCE_ROOT; };
|
6ACA41E915FC1D9000935EF6 /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = Source/Installer/AppDelegate.m; sourceTree = SOURCE_ROOT; };
|
||||||
|
@ -287,8 +288,6 @@
|
||||||
6A0D4ECA15FC0D6400ABF4B3 /* OVInputSourceHelper.m */,
|
6A0D4ECA15FC0D6400ABF4B3 /* OVInputSourceHelper.m */,
|
||||||
6A0D4ECB15FC0D6400ABF4B3 /* PreferencesWindowController.h */,
|
6A0D4ECB15FC0D6400ABF4B3 /* PreferencesWindowController.h */,
|
||||||
6A0D4ECC15FC0D6400ABF4B3 /* PreferencesWindowController.m */,
|
6A0D4ECC15FC0D6400ABF4B3 /* PreferencesWindowController.m */,
|
||||||
6A0D4ECD15FC0D6400ABF4B3 /* UpdateNotificationController.h */,
|
|
||||||
6A0D4ECE15FC0D6400ABF4B3 /* UpdateNotificationController.m */,
|
|
||||||
6AE30A471F7F40B7008735BD /* UserOverrideModel.cpp */,
|
6AE30A471F7F40B7008735BD /* UserOverrideModel.cpp */,
|
||||||
6AE30A481F7F40B7008735BD /* UserOverrideModel.h */,
|
6AE30A481F7F40B7008735BD /* UserOverrideModel.h */,
|
||||||
D427A9C025ED28CC005D43E0 /* OpenCCBridge.swift */,
|
D427A9C025ED28CC005D43E0 /* OpenCCBridge.swift */,
|
||||||
|
@ -570,7 +569,7 @@
|
||||||
);
|
);
|
||||||
mainGroup = 6A0D4E9215FC0CFA00ABF4B3;
|
mainGroup = 6A0D4E9215FC0CFA00ABF4B3;
|
||||||
packageReferences = (
|
packageReferences = (
|
||||||
D48550A125EBE689006A204C /* XCRemoteSwiftPackageReference "SwiftyOpenCC" */,
|
D48550A125EBE689006A204C /* XCRemoteSwiftPackageReference "SwiftyLibreCC" */,
|
||||||
);
|
);
|
||||||
productRefGroup = 6A0D4EA315FC0D2D00ABF4B3 /* Products */;
|
productRefGroup = 6A0D4EA315FC0D2D00ABF4B3 /* Products */;
|
||||||
projectDirPath = "";
|
projectDirPath = "";
|
||||||
|
@ -1133,9 +1132,9 @@
|
||||||
/* End XCConfigurationList section */
|
/* End XCConfigurationList section */
|
||||||
|
|
||||||
/* Begin XCRemoteSwiftPackageReference section */
|
/* Begin XCRemoteSwiftPackageReference section */
|
||||||
D48550A125EBE689006A204C /* XCRemoteSwiftPackageReference "SwiftyOpenCC" */ = {
|
D48550A125EBE689006A204C /* XCRemoteSwiftPackageReference "SwiftyLibreCC" */ = {
|
||||||
isa = XCRemoteSwiftPackageReference;
|
isa = XCRemoteSwiftPackageReference;
|
||||||
repositoryURL = "https://github.com/ddddxxx/SwiftyOpenCC.git";
|
repositoryURL = "https://dev.azure.com/ShikiSuen/vChewing/_git/SwiftyLibreCC";
|
||||||
requirement = {
|
requirement = {
|
||||||
kind = revision;
|
kind = revision;
|
||||||
revision = 1d8105a0f7199c90af722bff62728050c858e777;
|
revision = 1d8105a0f7199c90af722bff62728050c858e777;
|
||||||
|
@ -1146,7 +1145,7 @@
|
||||||
/* Begin XCSwiftPackageProductDependency section */
|
/* Begin XCSwiftPackageProductDependency section */
|
||||||
D48550A225EBE689006A204C /* OpenCC */ = {
|
D48550A225EBE689006A204C /* OpenCC */ = {
|
||||||
isa = XCSwiftPackageProductDependency;
|
isa = XCSwiftPackageProductDependency;
|
||||||
package = D48550A125EBE689006A204C /* XCRemoteSwiftPackageReference "SwiftyOpenCC" */;
|
package = D48550A125EBE689006A204C /* XCRemoteSwiftPackageReference "SwiftyLibreCC" */;
|
||||||
productName = OpenCC;
|
productName = OpenCC;
|
||||||
};
|
};
|
||||||
/* End XCSwiftPackageProductDependency section */
|
/* End XCSwiftPackageProductDependency section */
|
||||||
|
|
|
@ -0,0 +1,14 @@
|
||||||
|
# OpenVanilla McBopomofo 小麥注音輸入法
|
||||||
|
|
||||||
|
## 開發流程
|
||||||
|
|
||||||
|
用 Xcode 開啟 `McBopomofo.xcodeproj`,選 "McBopomofo Installer" target,build 完之後直接執行該安裝程式,就可以安裝小麥注音。
|
||||||
|
|
||||||
|
第一次安裝完,日後程式碼或詞庫有任何修改,只要重複上述流程,再次安裝小麥注音即可。
|
||||||
|
|
||||||
|
要注意的是 macOS 可能會限制同一次 login session 能 kill 同一個輸入法 process 的次數(安裝程式透過 kill input method process 來讓新版的輸入法生效)。如果安裝若干次後,發現程式修改的結果並沒有出現,或甚至輸入法已無法再選用,只要登出目前帳號再重新登入即可。
|
||||||
|
|
||||||
|
## 軟體授權
|
||||||
|
|
||||||
|
本專案採用 MIT License 釋出,使用者可自由使用、散播本軟體,惟散播時必須完整保留版權聲明及軟體授權([詳全文](https://github.com/openvanilla/McBopomofo/blob/master/LICENSE.txt))。
|
||||||
|
|
Loading…
Reference in New Issue