chore: generate template (#17)

This commit is contained in:
github-actions[bot]
2022-04-11 14:18:19 -05:00
committed by GitHub
parent 5baf0dfa61
commit 699457e663
249 changed files with 932 additions and 932 deletions

View File

@@ -0,0 +1,21 @@
import FlutterMacOS
import Foundation
public class {{project_name.pascalCase()}}Plugin: NSObject, FlutterPlugin {
public static func register(with registrar: FlutterPluginRegistrar) {
let channel = FlutterMethodChannel(
name: "{{project_name.snakeCase()}}_macos",
binaryMessenger: registrar.messenger)
let instance = {{project_name.pascalCase()}}Plugin()
registrar.addMethodCallDelegate(instance, channel: channel)
}
public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
switch call.method {
case "getPlatformName":
result("MacOS")
default:
result(FlutterMethodNotImplemented)
}
}
}

View File

@@ -0,0 +1,22 @@
#
# To learn more about a Podspec see http://guides.cocoapods.org/syntax/podspec.html
#
Pod::Spec.new do |s|
s.name = '{{project_name.snakeCase()}}_macos'
s.version = '0.0.1'
s.summary = 'A macOS implementation of the {{project_name.snakeCase()}} plugin.'
s.description = <<-DESC
A macOS implementation of the {{project_name.snakeCase()}} plugin.
DESC
s.homepage = 'http://example.com'
s.license = { :type => 'BSD', :file => '../LICENSE' }
s.author = { 'Your Company' => 'email@example.com' }
s.source = { :path => '.' }
s.source_files = 'Classes/**/*'
s.dependency 'FlutterMacOS'
s.platform = :osx
s.osx.deployment_target = '10.11'
s.swift_version = '5.0'
end