gonative-cli 1.5.6 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +33 -21
- data/lib/gonative/commands/ios/build.rb +19 -0
- data/lib/gonative/commands/ios/publish.rb +20 -5
- data/lib/gonative/commands/ios/version.rb +3 -5
- data/lib/gonative/commands.rb +1 -0
- data/lib/gonative/plugins/ios/build_framework.rb +223 -117
- data/lib/gonative/plugins/ios/create.rb +5 -2
- data/lib/gonative/plugins/ios/release.rb +162 -24
- data/lib/gonative/plugins/ios/verify.rb +1 -7
- data/lib/gonative/plugins/ios/version.rb +8 -8
- data/lib/gonative/utils/template_inflator.rb +8 -4
- data/lib/gonative/utils.rb +1 -1
- data/lib/gonative/version.rb +1 -1
- data/templates/plugins/android/plugin-metadata.json.erb +7 -0
- data/templates/plugins/android/src/main/{AndroidManifest.xml.tpl → AndroidManifest.xml.erb} +2 -2
- data/templates/plugins/android/src/main/java/io/gonative/android/plugins/JAVA_PACKAGE/{PLUGIN_NAME.java.tpl → PLUGIN_NAME.java.erb} +3 -3
- data/templates/plugins/ios/common/Package.swift.erb +28 -0
- data/templates/plugins/ios/common/Project.swift.erb +44 -0
- data/templates/plugins/ios/common/Resources/polyfill.js.erb +10 -0
- data/templates/plugins/ios/common/VERSION +1 -0
- data/templates/plugins/ios/common/Wrappers/dummy.m +1 -0
- data/templates/plugins/ios/common/Wrappers/include/dummy.h +1 -0
- data/templates/plugins/ios/language-specific/objc/{PLUGIN_NAME/Classes/GNPLUGIN_NAME.h.tpl → Classes/GNPLUGIN_NAME.h.erb} +4 -4
- data/templates/plugins/ios/language-specific/objc/Classes/GNPLUGIN_NAME.m.erb +14 -0
- data/templates/plugins/ios/language-specific/objc/Project.swift.erb +44 -0
- data/templates/plugins/ios/language-specific/swift/Classes/GNSwiftModule.m.erb +12 -0
- data/templates/plugins/ios/language-specific/swift/Classes/GNSwiftModule.swift.erb +14 -0
- data/templates/plugins/ios/language-specific/swift/Project.swift.erb +43 -0
- metadata +22 -25
- data/lib/gonative/utils/content_evaluator.rb +0 -16
- data/templates/build/ios/Info.plist +0 -28
- data/templates/build/ios/PLUGIN_NAME-umbrella.h.tpl +0 -16
- data/templates/build/ios/PLUGIN_NAME.modulemap.tpl +0 -6
- data/templates/build/ios/Podfile.tpl +0 -10
- data/templates/build/ios/create-framework.sh.tpl +0 -36
- data/templates/plugins/android/plugin-metadata.json.tpl +0 -7
- data/templates/plugins/ios/common/PLUGIN_NAME/Classes/Dummy.swift +0 -6
- data/templates/plugins/ios/common/PLUGIN_NAME/Resources/polyfill.js.tpl +0 -0
- data/templates/plugins/ios/common/PLUGIN_NAME.podspec.tpl +0 -30
- data/templates/plugins/ios/language-specific/objc/PLUGIN_NAME/Classes/GNPLUGIN_NAME.m.tpl +0 -14
- data/templates/plugins/ios/language-specific/swift/PLUGIN_NAME/Classes/GNSwiftModule.m.tpl +0 -12
- data/templates/plugins/ios/language-specific/swift/PLUGIN_NAME/Classes/GNSwiftModule.swift.tpl +0 -14
- /data/templates/plugins/ios/common/{PLUGIN_NAME/Frameworks → Frameworks}/.keep +0 -0
- /data/templates/plugins/ios/common/{PLUGIN_NAME/Info.plist → Info.plist} +0 -0
- /data/templates/plugins/ios/common/{PLUGIN_NAME/LICENSE → LICENSE} +0 -0
metadata
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gonative-cli
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 2.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Hunaid Hassan
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: bin
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
12
11
|
dependencies:
|
|
13
12
|
- !ruby/object:Gem::Dependency
|
|
14
13
|
name: activesupport
|
|
@@ -223,6 +222,7 @@ files:
|
|
|
223
222
|
- lib/gonative/commands/base.rb
|
|
224
223
|
- lib/gonative/commands/ios/add_files.rb
|
|
225
224
|
- lib/gonative/commands/ios/add_language.rb
|
|
225
|
+
- lib/gonative/commands/ios/build.rb
|
|
226
226
|
- lib/gonative/commands/ios/create.rb
|
|
227
227
|
- lib/gonative/commands/ios/embed_extensions.rb
|
|
228
228
|
- lib/gonative/commands/ios/embed_scripts.rb
|
|
@@ -255,32 +255,31 @@ files:
|
|
|
255
255
|
- lib/gonative/plugins/ios/verify.rb
|
|
256
256
|
- lib/gonative/plugins/ios/version.rb
|
|
257
257
|
- lib/gonative/utils.rb
|
|
258
|
-
- lib/gonative/utils/content_evaluator.rb
|
|
259
258
|
- lib/gonative/utils/sanitize_plugin_name.rb
|
|
260
259
|
- lib/gonative/utils/template_inflator.rb
|
|
261
260
|
- lib/gonative/utils/ui.rb
|
|
262
261
|
- lib/gonative/version.rb
|
|
263
|
-
- templates/build/ios/Info.plist
|
|
264
|
-
- templates/build/ios/PLUGIN_NAME-umbrella.h.tpl
|
|
265
|
-
- templates/build/ios/PLUGIN_NAME.modulemap.tpl
|
|
266
|
-
- templates/build/ios/Podfile.tpl
|
|
267
|
-
- templates/build/ios/create-framework.sh.tpl
|
|
268
262
|
- templates/plugins/android/build.gradle
|
|
269
263
|
- templates/plugins/android/consumer-rules.pro
|
|
270
|
-
- templates/plugins/android/plugin-metadata.json.
|
|
264
|
+
- templates/plugins/android/plugin-metadata.json.erb
|
|
271
265
|
- templates/plugins/android/proguard-rules.pro
|
|
272
|
-
- templates/plugins/android/src/main/AndroidManifest.xml.
|
|
273
|
-
- templates/plugins/android/src/main/java/io/gonative/android/plugins/JAVA_PACKAGE/PLUGIN_NAME.java.
|
|
274
|
-
- templates/plugins/ios/common/
|
|
275
|
-
- templates/plugins/ios/common/
|
|
276
|
-
- templates/plugins/ios/common/
|
|
277
|
-
- templates/plugins/ios/common/
|
|
278
|
-
- templates/plugins/ios/common/
|
|
279
|
-
- templates/plugins/ios/common/
|
|
280
|
-
- templates/plugins/ios/
|
|
281
|
-
- templates/plugins/ios/
|
|
282
|
-
- templates/plugins/ios/
|
|
283
|
-
- templates/plugins/ios/language-specific/
|
|
266
|
+
- templates/plugins/android/src/main/AndroidManifest.xml.erb
|
|
267
|
+
- templates/plugins/android/src/main/java/io/gonative/android/plugins/JAVA_PACKAGE/PLUGIN_NAME.java.erb
|
|
268
|
+
- templates/plugins/ios/common/Frameworks/.keep
|
|
269
|
+
- templates/plugins/ios/common/Info.plist
|
|
270
|
+
- templates/plugins/ios/common/LICENSE
|
|
271
|
+
- templates/plugins/ios/common/Package.swift.erb
|
|
272
|
+
- templates/plugins/ios/common/Project.swift.erb
|
|
273
|
+
- templates/plugins/ios/common/Resources/polyfill.js.erb
|
|
274
|
+
- templates/plugins/ios/common/VERSION
|
|
275
|
+
- templates/plugins/ios/common/Wrappers/dummy.m
|
|
276
|
+
- templates/plugins/ios/common/Wrappers/include/dummy.h
|
|
277
|
+
- templates/plugins/ios/language-specific/objc/Classes/GNPLUGIN_NAME.h.erb
|
|
278
|
+
- templates/plugins/ios/language-specific/objc/Classes/GNPLUGIN_NAME.m.erb
|
|
279
|
+
- templates/plugins/ios/language-specific/objc/Project.swift.erb
|
|
280
|
+
- templates/plugins/ios/language-specific/swift/Classes/GNSwiftModule.m.erb
|
|
281
|
+
- templates/plugins/ios/language-specific/swift/Classes/GNSwiftModule.swift.erb
|
|
282
|
+
- templates/plugins/ios/language-specific/swift/Project.swift.erb
|
|
284
283
|
homepage: https://www.github.com/gonativeio/gonative-cli
|
|
285
284
|
licenses:
|
|
286
285
|
- MIT
|
|
@@ -289,7 +288,6 @@ metadata:
|
|
|
289
288
|
source_code_uri: https://www.github.com/gonativeio/gonative-cli
|
|
290
289
|
changelog_uri: https://www.github.com/gonativeio/gonative-cli/blob/master/CHANGELOG.md
|
|
291
290
|
github_repo: ssh://github.com/gonativeio/gonative-cli
|
|
292
|
-
post_install_message:
|
|
293
291
|
rdoc_options: []
|
|
294
292
|
require_paths:
|
|
295
293
|
- lib
|
|
@@ -304,8 +302,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
304
302
|
- !ruby/object:Gem::Version
|
|
305
303
|
version: '0'
|
|
306
304
|
requirements: []
|
|
307
|
-
rubygems_version: 3.
|
|
308
|
-
signing_key:
|
|
305
|
+
rubygems_version: 3.7.1
|
|
309
306
|
specification_version: 4
|
|
310
307
|
summary: CLI to create gonative plugins.
|
|
311
308
|
test_files: []
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
require 'ostruct'
|
|
4
|
-
|
|
5
|
-
module GoNative
|
|
6
|
-
module Utils
|
|
7
|
-
class ContentEvaluator
|
|
8
|
-
class << self
|
|
9
|
-
def call(content, values)
|
|
10
|
-
o = OpenStruct.new(values)
|
|
11
|
-
o.instance_eval('"' + content.gsub('"', '\\\\"') + '"')
|
|
12
|
-
end
|
|
13
|
-
end
|
|
14
|
-
end
|
|
15
|
-
end
|
|
16
|
-
end
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
3
|
-
<plist version="1.0">
|
|
4
|
-
<dict>
|
|
5
|
-
<key>CFBundleDevelopmentRegion</key>
|
|
6
|
-
<string>${PODS_DEVELOPMENT_LANGUAGE}</string>
|
|
7
|
-
<key>CFBundleExecutable</key>
|
|
8
|
-
<string>${EXECUTABLE_NAME}</string>
|
|
9
|
-
<key>CFBundleIdentifier</key>
|
|
10
|
-
<string>${PRODUCT_BUNDLE_IDENTIFIER}</string>
|
|
11
|
-
<key>CFBundleInfoDictionaryVersion</key>
|
|
12
|
-
<string>6.0</string>
|
|
13
|
-
<key>CFBundleName</key>
|
|
14
|
-
<string>${PRODUCT_NAME}</string>
|
|
15
|
-
<key>CFBundlePackageType</key>
|
|
16
|
-
<string>FMWK</string>
|
|
17
|
-
<key>CFBundleShortVersionString</key>
|
|
18
|
-
<string>${MARKETING_VERSION}</string>
|
|
19
|
-
<key>GNLibraryVersion</key>
|
|
20
|
-
<string>${MARKETING_VERSION}</string>
|
|
21
|
-
<key>CFBundleSignature</key>
|
|
22
|
-
<string>????</string>
|
|
23
|
-
<key>CFBundleVersion</key>
|
|
24
|
-
<string>${CURRENT_PROJECT_VERSION}</string>
|
|
25
|
-
<key>NSPrincipalClass</key>
|
|
26
|
-
<string></string>
|
|
27
|
-
</dict>
|
|
28
|
-
</plist>
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
#ifdef __OBJC__
|
|
2
|
-
#import <UIKit/UIKit.h>
|
|
3
|
-
#else
|
|
4
|
-
#ifndef FOUNDATION_EXPORT
|
|
5
|
-
#if defined(__cplusplus)
|
|
6
|
-
#define FOUNDATION_EXPORT extern "C"
|
|
7
|
-
#else
|
|
8
|
-
#define FOUNDATION_EXPORT extern
|
|
9
|
-
#endif
|
|
10
|
-
#endif
|
|
11
|
-
#endif
|
|
12
|
-
|
|
13
|
-
#{plugin_headers}
|
|
14
|
-
|
|
15
|
-
FOUNDATION_EXPORT double #{plugin_name}VersionNumber;
|
|
16
|
-
FOUNDATION_EXPORT const unsigned char #{plugin_name}VersionString[];
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
set -e
|
|
3
|
-
|
|
4
|
-
WORKING_DIR=$(pwd)
|
|
5
|
-
|
|
6
|
-
FRAMEWORK_FOLDER_NAME="Frameworks"
|
|
7
|
-
|
|
8
|
-
FRAMEWORK_NAME="#{plugin_name}"
|
|
9
|
-
|
|
10
|
-
FRAMEWORK_PATH="${WORKING_DIR}/${FRAMEWORK_FOLDER_NAME}/${FRAMEWORK_NAME}.xcframework"
|
|
11
|
-
|
|
12
|
-
BUILD_SCHEME="#{plugin_name}"
|
|
13
|
-
|
|
14
|
-
SIMULATOR_ARCHIVE_PATH="${WORKING_DIR}/${FRAMEWORK_FOLDER_NAME}/simulator.xcarchive"
|
|
15
|
-
|
|
16
|
-
IOS_DEVICE_ARCHIVE_PATH="${WORKING_DIR}/${FRAMEWORK_FOLDER_NAME}/iOS.xcarchive"
|
|
17
|
-
|
|
18
|
-
rm -rf "${WORKING_DIR}/${FRAMEWORK_FOLDER_NAME}"
|
|
19
|
-
echo "Deleted ${FRAMEWORK_FOLDER_NAME}"
|
|
20
|
-
mkdir "${FRAMEWORK_FOLDER_NAME}"
|
|
21
|
-
echo "Created ${FRAMEWORK_FOLDER_NAME}"
|
|
22
|
-
echo "Archiving ${FRAMEWORK_NAME}"
|
|
23
|
-
|
|
24
|
-
xcodebuild -workspace "#{plugin_name}.xcworkspace" archive ONLY_ACTIVE_ARCH=NO ARCHS="#{archs}" -scheme ${BUILD_SCHEME} -destination="generic/platform=iOS Simulator" -archivePath "${SIMULATOR_ARCHIVE_PATH}" -sdk iphonesimulator SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
|
|
25
|
-
|
|
26
|
-
xcodebuild archive -workspace "#{plugin_name}.xcworkspace" -scheme ${BUILD_SCHEME} -destination="generic/platform=iOS" -archivePath "${IOS_DEVICE_ARCHIVE_PATH}" -sdk iphoneos SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
|
|
27
|
-
|
|
28
|
-
xcodebuild -create-xcframework \
|
|
29
|
-
-framework ${SIMULATOR_ARCHIVE_PATH}/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \
|
|
30
|
-
-debug-symbols ${SIMULATOR_ARCHIVE_PATH}/dSYMs/${FRAMEWORK_NAME}.framework.dSYM \
|
|
31
|
-
-framework ${IOS_DEVICE_ARCHIVE_PATH}/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \
|
|
32
|
-
-debug-symbols ${IOS_DEVICE_ARCHIVE_PATH}/dSYMs/${FRAMEWORK_NAME}.framework.dSYM \
|
|
33
|
-
-output "${FRAMEWORK_PATH}"
|
|
34
|
-
|
|
35
|
-
rm -rf "${SIMULATOR_ARCHIVE_PATH}"
|
|
36
|
-
rm -rf "${IOS_DEVICE_ARCHIVE_PATH}"
|
|
File without changes
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
Pod::Spec.new do |s|
|
|
2
|
-
s.name = '#{plugin_name}'
|
|
3
|
-
s.version = '0.1.0'
|
|
4
|
-
s.summary = '#{plugin_name} for Median.'
|
|
5
|
-
|
|
6
|
-
s.description = <<-DESC
|
|
7
|
-
TODO: Add long description of the pod here.
|
|
8
|
-
DESC
|
|
9
|
-
|
|
10
|
-
s.homepage = 'https://median.co'
|
|
11
|
-
s.license = { :type => 'Proprietary', :file => '#{plugin_name}/LICENSE' }
|
|
12
|
-
s.author = { 'hunaid' => 'hunaid@median.co' }
|
|
13
|
-
s.source = { :http => "https://pods.median.co/#{plugin_name}/#{plugin_name}-v#{s.version.to_s}.zip" }
|
|
14
|
-
|
|
15
|
-
s.ios.deployment_target = '15.5'
|
|
16
|
-
s.swift_versions = '5.0'
|
|
17
|
-
|
|
18
|
-
s.subspec 'Source' do |cs|
|
|
19
|
-
cs.source_files = '#{plugin_name}/Classes/**/*.{h,m,swift}'
|
|
20
|
-
cs.resource_bundle = { '#{plugin_name}JS' => '#{plugin_name}/Resources/*.{js,json}' }
|
|
21
|
-
end
|
|
22
|
-
|
|
23
|
-
s.subspec 'Binary' do |cs|
|
|
24
|
-
cs.ios.vendored_frameworks = '#{plugin_name}/Frameworks/#{plugin_name}.xcframework'
|
|
25
|
-
cs.resource_bundle = { '#{plugin_name}JS' => '#{plugin_name}/Resources/*.{js,json}' }
|
|
26
|
-
end
|
|
27
|
-
|
|
28
|
-
s.default_subspec = 'Binary'
|
|
29
|
-
s.dependency 'GoNativeCore'
|
|
30
|
-
end
|
|
File without changes
|
|
File without changes
|
|
File without changes
|