Skip to content

Commit

Permalink
chore(camera): Adding SPM support to camera (#1930)
Browse files Browse the repository at this point in the history
Co-authored-by: Mike Summerfeldt <20338451+IT-MikeS@users.noreply.github.com>
  • Loading branch information
theproducer and IT-MikeS committed Dec 7, 2023
1 parent e7b00b4 commit 0e1e1d5
Show file tree
Hide file tree
Showing 24 changed files with 85 additions and 858 deletions.
7 changes: 7 additions & 0 deletions camera/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@ Pods
Podfile.lock
Build
xcuserdata
/.build
/Packages
xcuserdata/
DerivedData/
.swiftpm/configuration/registries.json
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata
.netrc

# macOS files
.DS_Store
Expand Down
2 changes: 1 addition & 1 deletion camera/CapacitorCamera.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Pod::Spec.new do |s|
s.homepage = 'https://capacitorjs.com'
s.author = package['author']
s.source = { :git => 'https://github.com/ionic-team/capacitor-plugins.git', :tag => package['name'] + '@' + package['version'] }
s.source_files = 'ios/Plugin/**/*.{swift,h,m,c,cc,mm,cpp}', 'camera/ios/Plugin/**/*.{swift,h,m,c,cc,mm,cpp}'
s.source_files = 'ios/Sources/**/*.{swift,h,m,c,cc,mm,cpp}', 'camera/ios/Sources/**/*.{swift,h,m,c,cc,mm,cpp}'
s.ios.deployment_target = '13.0'
s.dependency 'Capacitor'
s.swift_version = '5.1'
Expand Down
14 changes: 14 additions & 0 deletions camera/Package.resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"pins" : [
{
"identity" : "capacitor6-spm-test",
"kind" : "remoteSourceControl",
"location" : "https://github.com/ionic-team/capacitor6-spm-test.git",
"state" : {
"branch" : "main",
"revision" : "cf4ff2bc1dffb14adc27b1e5a09ac37e85424b99"
}
}
],
"version" : 2
}
28 changes: 28 additions & 0 deletions camera/Package.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// swift-tools-version: 5.9
import PackageDescription

let package = Package(
name: "CapacitorCamera",
platforms: [.iOS(.v13)],
products: [
.library(
name: "CameraPlugin",
targets: ["CameraPlugin"])
],
dependencies: [
.package(url: "https://github.com/ionic-team/capacitor6-spm-test.git", branch: "main")
],
targets: [
.target(
name: "CameraPlugin",
dependencies: [
.product(name: "Capacitor", package: "capacitor6-spm-test"),
.product(name: "Cordova", package: "capacitor6-spm-test")
],
path: "ios/Sources/CameraPlugin"),
.testTarget(
name: "CameraPluginTests",
dependencies: ["CameraPlugin"],
path: "ios/Tests/CameraPluginTests")
]
)
8 changes: 8 additions & 0 deletions camera/ios/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.DS_Store
/.build
/Packages
xcuserdata/
DerivedData/
.swiftpm/configuration/registries.json
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata
.netrc
Loading

0 comments on commit 0e1e1d5

Please sign in to comment.