segue_handler_plugin 0.0.1

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.
Files changed (51) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +30 -0
  3. data/Example/.ruby-version +1 -0
  4. data/Example/Gemfile +5 -0
  5. data/Example/Gemfile.lock +71 -0
  6. data/Example/Podfile +6 -0
  7. data/Example/Podfile.lock +14 -0
  8. data/Example/Pods/Headers/Private/WillowTreeSegueHandler/SegueHandler.h +19 -0
  9. data/Example/Pods/Local Podspecs/WillowTreeSegueHandler.podspec.json +25 -0
  10. data/Example/Pods/Manifest.lock +14 -0
  11. data/Example/Pods/Pods.xcodeproj/project.pbxproj +523 -0
  12. data/Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/WillowTreeSegueHandler.xcscheme +60 -0
  13. data/Example/Pods/Target Support Files/Pods/Info.plist +26 -0
  14. data/Example/Pods/Target Support Files/Pods/Pods-acknowledgements.markdown +26 -0
  15. data/Example/Pods/Target Support Files/Pods/Pods-acknowledgements.plist +56 -0
  16. data/Example/Pods/Target Support Files/Pods/Pods-dummy.m +5 -0
  17. data/Example/Pods/Target Support Files/Pods/Pods-frameworks.sh +91 -0
  18. data/Example/Pods/Target Support Files/Pods/Pods-resources.sh +95 -0
  19. data/Example/Pods/Target Support Files/Pods/Pods-umbrella.h +6 -0
  20. data/Example/Pods/Target Support Files/Pods/Pods.debug.xcconfig +8 -0
  21. data/Example/Pods/Target Support Files/Pods/Pods.modulemap +6 -0
  22. data/Example/Pods/Target Support Files/Pods/Pods.release.xcconfig +8 -0
  23. data/Example/Pods/Target Support Files/WillowTreeSegueHandler/Info.plist +26 -0
  24. data/Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler-dummy.m +5 -0
  25. data/Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler-prefix.pch +4 -0
  26. data/Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler-umbrella.h +7 -0
  27. data/Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler.modulemap +6 -0
  28. data/Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler.xcconfig +5 -0
  29. data/Example/SegueBuilder.xcodeproj/project.pbxproj +390 -0
  30. data/Example/SegueBuilder.xcodeproj/project.xcworkspace/contents.xcworkspacedata +7 -0
  31. data/Example/SegueBuilder.xcworkspace/contents.xcworkspacedata +10 -0
  32. data/Example/SegueBuilder/AppDelegate.swift +49 -0
  33. data/Example/SegueBuilder/Assets.xcassets/AppIcon.appiconset/Contents.json +73 -0
  34. data/Example/SegueBuilder/Base.lproj/LaunchScreen.storyboard +27 -0
  35. data/Example/SegueBuilder/Base.lproj/Main.storyboard +151 -0
  36. data/Example/SegueBuilder/Info.plist +45 -0
  37. data/Example/SegueBuilder/SegueExtensions.swift +57 -0
  38. data/Example/SegueBuilder/ViewControllers.swift +77 -0
  39. data/Example/Storyboards.swift +0 -0
  40. data/Example/test.sh +20 -0
  41. data/LICENSE +19 -0
  42. data/README.md +75 -0
  43. data/WillowTreeSegueHandler.podspec +23 -0
  44. data/exe/segue-handler-generator +1107 -0
  45. data/exe/segue-handler-generator-build +30 -0
  46. data/lib/cocoapods_plugin.rb +1 -0
  47. data/lib/pod/command/generate_segue_handlers.rb +31 -0
  48. data/lib/segue_handler_plugin.rb +4 -0
  49. data/lib/segue_handler_plugin/version.rb +3 -0
  50. data/segue_handler_plugin.gemspec +20 -0
  51. metadata +95 -0
@@ -0,0 +1,30 @@
1
+ require 'tempfile'
2
+ t = Tempfile.new("generate-segue-handlers.sh")
3
+ t << <<-BASH
4
+ echo "Segue Generator: Determining if generated Swift file is up-to-date."
5
+
6
+ GENERATOR_PATH="segue-handler-generator"
7
+
8
+ BASE_PATH="$PROJECT_DIR/$PROJECT_NAME"
9
+ echo "WHUT"
10
+ echo $BASE_PATH
11
+ echo "WHUT"
12
+ OUTPUT_PATH="$BASE_PATH/SegueExtensions.swift"
13
+
14
+ if [ ! -e "$OUTPUT_PATH" ] || [ -n "$(find "$BASE_PATH" -type f -name "*.storyboard" -newer "$OUTPUT_PATH" -print -quit)" ]; then
15
+ echo "Segue Generator: Generated Swift is out-of-date; re-generating..."
16
+
17
+ if [ -f $OUTPUT_PATH ]; then
18
+ /usr/bin/chflags -f nouchg "$OUTPUT_PATH"
19
+ fi
20
+ "$GENERATOR_PATH" "$BASE_PATH" > "$OUTPUT_PATH"
21
+ /usr/bin/chflags uchg "$OUTPUT_PATH"
22
+
23
+ echo "Segue Generator: Done."
24
+ else
25
+ echo "Segue Generator: Generated Swift is up-to-date; skipping re-generation."
26
+ fi
27
+ BASH
28
+
29
+ t.close
30
+ puts `PROJECT_DIR=#{ENV['PROJECT_DIR']} PROJECT_NAME=#{ENV['PROJECT_NAME']} /bin/sh #{t.path}`
@@ -0,0 +1 @@
1
+ require 'pod/command/generate_segue_handlers'
@@ -0,0 +1,31 @@
1
+ module Pod
2
+ class Command
3
+ class GenerateSegueHandlers < Command
4
+
5
+ self.summary = 'Generate segue handlers for the project'
6
+ self.description = <<-DESC
7
+ Generate segue handlers for storyboards in this project.
8
+ DESC
9
+
10
+ def self.options
11
+ []
12
+ end
13
+
14
+ def initialize(argv)
15
+ unless argv.empty?
16
+ @project_dir = argv.shift_argument
17
+ @project_name = argv.shift_argument
18
+ end
19
+ super
20
+ end
21
+
22
+ def validate!
23
+ super
24
+ end
25
+
26
+ def run
27
+ puts `PROJECT_DIR=#{@project_dir} PROJECT_NAME=#{@project_name} segue-handler-generator-build`
28
+ end
29
+ end
30
+ end
31
+ end
@@ -0,0 +1,4 @@
1
+ require "segue_handler_plugin/version"
2
+
3
+ module SegueHandlerPlugin
4
+ end
@@ -0,0 +1,3 @@
1
+ module SegueHandlerPlugin
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,20 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'segue_handler_plugin/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "segue_handler_plugin"
8
+ spec.version = SegueHandlerPlugin::VERSION
9
+ spec.authors = ["Ian Terrell"]
10
+ spec.email = ["ian.terrell@willowtreeapps.com"]
11
+
12
+ spec.summary = %q{Generates segue handlers for use with a pod}
13
+ spec.homepage = "https://github.com/willowtreeapps/segue_handler"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features|SegueHandler)/}) }
17
+ spec.bindir = "exe"
18
+ spec.executables = ["segue-handler-generator", "segue-handler-generator-build"]
19
+ spec.require_paths = ["lib"]
20
+ end
metadata ADDED
@@ -0,0 +1,95 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: segue_handler_plugin
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Ian Terrell
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2016-02-19 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description:
14
+ email:
15
+ - ian.terrell@willowtreeapps.com
16
+ executables:
17
+ - segue-handler-generator
18
+ - segue-handler-generator-build
19
+ extensions: []
20
+ extra_rdoc_files: []
21
+ files:
22
+ - ".gitignore"
23
+ - Example/.ruby-version
24
+ - Example/Gemfile
25
+ - Example/Gemfile.lock
26
+ - Example/Podfile
27
+ - Example/Podfile.lock
28
+ - Example/Pods/Headers/Private/WillowTreeSegueHandler/SegueHandler.h
29
+ - Example/Pods/Local Podspecs/WillowTreeSegueHandler.podspec.json
30
+ - Example/Pods/Manifest.lock
31
+ - Example/Pods/Pods.xcodeproj/project.pbxproj
32
+ - Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/WillowTreeSegueHandler.xcscheme
33
+ - Example/Pods/Target Support Files/Pods/Info.plist
34
+ - Example/Pods/Target Support Files/Pods/Pods-acknowledgements.markdown
35
+ - Example/Pods/Target Support Files/Pods/Pods-acknowledgements.plist
36
+ - Example/Pods/Target Support Files/Pods/Pods-dummy.m
37
+ - Example/Pods/Target Support Files/Pods/Pods-frameworks.sh
38
+ - Example/Pods/Target Support Files/Pods/Pods-resources.sh
39
+ - Example/Pods/Target Support Files/Pods/Pods-umbrella.h
40
+ - Example/Pods/Target Support Files/Pods/Pods.debug.xcconfig
41
+ - Example/Pods/Target Support Files/Pods/Pods.modulemap
42
+ - Example/Pods/Target Support Files/Pods/Pods.release.xcconfig
43
+ - Example/Pods/Target Support Files/WillowTreeSegueHandler/Info.plist
44
+ - Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler-dummy.m
45
+ - Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler-prefix.pch
46
+ - Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler-umbrella.h
47
+ - Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler.modulemap
48
+ - Example/Pods/Target Support Files/WillowTreeSegueHandler/WillowTreeSegueHandler.xcconfig
49
+ - Example/SegueBuilder.xcodeproj/project.pbxproj
50
+ - Example/SegueBuilder.xcodeproj/project.xcworkspace/contents.xcworkspacedata
51
+ - Example/SegueBuilder.xcworkspace/contents.xcworkspacedata
52
+ - Example/SegueBuilder/AppDelegate.swift
53
+ - Example/SegueBuilder/Assets.xcassets/AppIcon.appiconset/Contents.json
54
+ - Example/SegueBuilder/Base.lproj/LaunchScreen.storyboard
55
+ - Example/SegueBuilder/Base.lproj/Main.storyboard
56
+ - Example/SegueBuilder/Info.plist
57
+ - Example/SegueBuilder/SegueExtensions.swift
58
+ - Example/SegueBuilder/ViewControllers.swift
59
+ - Example/Storyboards.swift
60
+ - Example/test.sh
61
+ - LICENSE
62
+ - README.md
63
+ - WillowTreeSegueHandler.podspec
64
+ - exe/segue-handler-generator
65
+ - exe/segue-handler-generator-build
66
+ - lib/cocoapods_plugin.rb
67
+ - lib/pod/command/generate_segue_handlers.rb
68
+ - lib/segue_handler_plugin.rb
69
+ - lib/segue_handler_plugin/version.rb
70
+ - segue_handler_plugin.gemspec
71
+ homepage: https://github.com/willowtreeapps/segue_handler
72
+ licenses:
73
+ - MIT
74
+ metadata: {}
75
+ post_install_message:
76
+ rdoc_options: []
77
+ require_paths:
78
+ - lib
79
+ required_ruby_version: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - ">="
82
+ - !ruby/object:Gem::Version
83
+ version: '0'
84
+ required_rubygems_version: !ruby/object:Gem::Requirement
85
+ requirements:
86
+ - - ">="
87
+ - !ruby/object:Gem::Version
88
+ version: '0'
89
+ requirements: []
90
+ rubyforge_project:
91
+ rubygems_version: 2.4.5
92
+ signing_key:
93
+ specification_version: 4
94
+ summary: Generates segue handlers for use with a pod
95
+ test_files: []