Skip to content

Commit

Permalink
Merge pull request #114 from qwertyyb/feature/cocoapods-to-spm
Browse files Browse the repository at this point in the history
feat: 依赖从 cocoapods 迁移至 Swift Package Manager
  • Loading branch information
qwertyyb authored Sep 16, 2023
2 parents 5e82fce + 3eca6cd commit b4f3598
Show file tree
Hide file tree
Showing 35 changed files with 533,006 additions and 714 deletions.
14 changes: 2 additions & 12 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ jobs:
retention-days: 2

build_binary:
runs-on: macOS-latest
runs-on: macos-13
needs: create_release

steps:
Expand All @@ -76,17 +76,7 @@ jobs:
git checkout $version
- name: switch xcode version
run: sudo xcode-select --switch /Applications/Xcode_13.2.1.app

- uses: actions/cache@v2
with:
path: Pods
key: ${{ runner.os }}-pods-${{ hashFiles('**/Podfile.lock') }}
restore-keys: |
${{ runner.os }}-pods-
- name: install depencies
run: pod install
run: sudo xcode-select --switch /Applications/Xcode_14.3.1.app

- name: import application certificate
id: keychain
Expand Down
25 changes: 13 additions & 12 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,49 +6,50 @@ on:
- master
pull_request:
types: [opened, reopened, synchronize]
workflow_dispatch:
inputs:
disable_sign:
description: '禁用签名'
required: false
type: boolean

jobs:
build-test:
runs-on: macOS-latest
runs-on: macos-13

steps:
- uses: actions/checkout@v1

- name: switch xcode version
run: sudo xcode-select --switch /Applications/Xcode_13.2.1.app

- uses: actions/cache@v2
with:
path: Pods
key: ${{ runner.os }}-pods-${{ hashFiles('**/Podfile.lock') }}
restore-keys: |
${{ runner.os }}-pods-
- name: install depencies
run: pod install
run: sudo xcode-select --switch /Applications/Xcode_14.3.1.app

- name: import application certificate
id: keychain
uses: apple-actions/import-codesign-certs@v1
if: ${{ !inputs.disable_sign && github.actor_id == github.repository_owner_id }}
with:
p12-file-base64: ${{ secrets.CERTIFICATES_P12 }}
p12-password: ${{ secrets.CERTIFICATES_P12_PASSWORD }}

- name: import installer certificate
uses: apple-actions/import-codesign-certs@v1
if: ${{ !inputs.disable_sign && github.actor_id == github.repository_owner_id }}
with:
create-keychain: false
keychain-password: ${{ steps.keychain.outputs.keychain-password }}
p12-file-base64: ${{ secrets.CERTIFICATES_INSTALLER_P12 }}
p12-password: ${{ secrets.CERTIFICATES_INSTALLER_P12_PASSWORD }}

- name: build Fire.app
env:
USE_CODE_SIGN: ${{ !inputs.disable_sign && github.actor_id == github.repository_owner_id && 'enable' || 'disable' }}
run: ./scripts/a_build_app.sh

- name: build FireInstaller.pkg
run: ./scripts/b_build_installer.sh

- name: generate appcast.xml
if: ${{ !inputs.disable_sign && github.actor_id == github.repository_owner_id }}
env:
sparkle_key: ${{ secrets.sparkle_key }}
run: ./scripts/d_build_appcast.sh
Expand Down
6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,9 @@ DerivedData/
!default.mode2v3
*.perspectivev3
!default.perspectivev3
xcuserdata/
# xcode构建有bug,需要把runner.xcuserdatad目录提交上来才,github action才能正常构建
/Fire.xcodeproj/project.xcworkspace/xcuserdata/*
!runner.xcuserdatad

## Other
*.moved-aside
Expand Down Expand Up @@ -86,7 +88,7 @@ playground.xcworkspace
# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
Pods/
# Add this line if you want to avoid checking in source code from the Xcode workspace
*.xcworkspace
# *.xcworkspace

# Carthage
# Add this line if you want to avoid checking in source code from Carthage dependencies.
Expand Down
897 changes: 460 additions & 437 deletions Fire.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions Fire.xcodeproj/project.xcworkspace/contents.xcworkspacedata

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict/>
</plist>
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"pins" : [
{
"identity" : "defaults",
"kind" : "remoteSourceControl",
"location" : "https://github.com/sindresorhus/Defaults",
"state" : {
"branch" : "main",
"revision" : "3efef5a28ebdbbe922d4a2049493733ed14475a6"
}
},
{
"identity" : "keychain-swift",
"kind" : "remoteSourceControl",
"location" : "https://github.com/evgenyneu/keychain-swift.git",
"state" : {
"revision" : "d108a1fa6189e661f91560548ef48651ed8d93b9",
"version" : "20.0.0"
}
},
{
"identity" : "nanoid",
"kind" : "remoteSourceControl",
"location" : "https://github.com/Tundaware/NanoID.git",
"state" : {
"revision" : "88fbf9ae2cb3962f0085ff29ad3b4a908df31f1f",
"version" : "1.0.4"
}
},
{
"identity" : "settings",
"kind" : "remoteSourceControl",
"location" : "https://github.com/sindresorhus/Settings",
"state" : {
"revision" : "b99f45cba818a9d483fb58e9b31de5dee799e315",
"version" : "3.0.3"
}
},
{
"identity" : "sparkle",
"kind" : "remoteSourceControl",
"location" : "https://github.com/sparkle-project/Sparkle",
"state" : {
"revision" : "c0933a516b420806e9216e71bd13ba76c54f0de6",
"version" : "1.26.0"
}
}
],
"version" : 2
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>BuildLocationStyle</key>
<string>UseAppPreferences</string>
<key>CustomBuildLocationType</key>
<string>RelativeToDerivedData</string>
<key>DerivedDataLocationStyle</key>
<string>Default</string>
<key>ShowSharedSchemesAutomaticallyEnabled</key>
<true/>
</dict>
</plist>
17 changes: 8 additions & 9 deletions Fire.xcodeproj/xcshareddata/xcschemes/Fire.xcscheme
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1200"
version = "1.3">
LastUpgradeVersion = "1430"
version = "1.7">
<BuildAction
parallelizeBuildables = "NO"
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
Expand All @@ -14,7 +14,7 @@
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "451E6043232E227B007B0463"
BlueprintIdentifier = "67C99FE72AB53DB2000B5281"
BuildableName = "Fire.app"
BlueprintName = "Fire"
ReferencedContainer = "container:Fire.xcodeproj">
Expand All @@ -26,9 +26,8 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
Expand All @@ -53,7 +52,7 @@
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "451E6043232E227B007B0463"
BlueprintIdentifier = "67C99FE72AB53DB2000B5281"
BuildableName = "Fire.app"
BlueprintName = "Fire"
ReferencedContainer = "container:Fire.xcodeproj">
Expand All @@ -70,7 +69,7 @@
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "451E6043232E227B007B0463"
BlueprintIdentifier = "67C99FE72AB53DB2000B5281"
BuildableName = "Fire.app"
BlueprintName = "Fire"
ReferencedContainer = "container:Fire.xcodeproj">
Expand Down
18 changes: 9 additions & 9 deletions Fire.xcodeproj/xcshareddata/xcschemes/TableBuilder.xcscheme
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1200"
version = "1.3">
LastUpgradeVersion = "1430"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
Expand All @@ -14,7 +14,7 @@
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "45577E5E25442E240064325B"
BlueprintIdentifier = "6753419A2AB54A3A00757F76"
BuildableName = "TableBuilder"
BlueprintName = "TableBuilder"
ReferencedContainer = "container:Fire.xcodeproj">
Expand All @@ -26,9 +26,8 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
Expand All @@ -39,12 +38,13 @@
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
allowLocationSimulation = "YES"
viewDebuggingEnabled = "No">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "45577E5E25442E240064325B"
BlueprintIdentifier = "6753419A2AB54A3A00757F76"
BuildableName = "TableBuilder"
BlueprintName = "TableBuilder"
ReferencedContainer = "container:Fire.xcodeproj">
Expand All @@ -61,7 +61,7 @@
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "45577E5E25442E240064325B"
BlueprintIdentifier = "6753419A2AB54A3A00757F76"
BuildableName = "TableBuilder"
BlueprintName = "TableBuilder"
ReferencedContainer = "container:Fire.xcodeproj">
Expand Down
84 changes: 0 additions & 84 deletions Fire.xcodeproj/xcshareddata/xcschemes/build-dict.xcscheme

This file was deleted.

Loading

0 comments on commit b4f3598

Please sign in to comment.