-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from jasonnam/develop
Release 0.2.0
- Loading branch information
Showing
14 changed files
with
91 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
language: ruby | ||
deploy: | ||
provider: rubygems | ||
gem: fastlane-plugin-copy | ||
api_key: $RUBYGEMS_API_KEY | ||
gem: fastlane-plugin-file_manager | ||
api_key: "$RUBYGEMS_API_KEY" | ||
on: | ||
branch: master | ||
env: | ||
global: | ||
secure: qH91MR+kiPtyWcPnbr3ikc4gbFJrnTH/dYbBG/Lj6xyiGwsW3TlGToYBOCjyuaCOJ+wtbL8r+T6t7XXp4EMqtPweRxnp0flNF+l1OKiWRJ9oiZ9G6UrJ6S2xnBfyMhLHpSQAmOHUcZjwjuy9Wb0rTryUoAPi+Wa73nYUSigNyBSOCTcPGw55fYEyOPDUe6aAyNCoxoytX5rhW3bbNxd6rwFdfGyf8AzAA0d++nsaxHO+qBP0JHELTZh7CRDGvueQ8APw/UtMLsTLwcHnMBeJPtcxF1Ln9+3V8tXL1C7wjxsjimRbMGK77HBGbD178frWMMXrLN/bTdFiXRAqjvAq95wPe6bQXJx39TRGAY9C1V/KXjAjH0MHq3YzRRB0xZ0N03s5GiI2YI5f4umdWlrCPfuqcKzdkiPdzuTtoCXvF3rt8OMcCyVwfQqBIJsH6PzAP3rzmf0CLJYmQxKvRXVraL2IKFKPi2RfVUJbaq2szOzQ6lQIum1h5RIy7LZLLk364tlzQsyV579jQgwteOBeaBTmm2r8wi0fizgrgFSfEPWL4wzwu89pCn88SOC7rlwCnCy7mftWT0Z3gOCP+zuF/QXoAI8BII+8wVVCy+EUDQ+Z40+J73CZa844kW1Ck7WqHUa2N2FQcScHDKpjaJklx1b5MmdZS5wovKNoO12YB0s= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,27 +2,22 @@ | |
|
||
lib = File.expand_path("../lib", __FILE__) | ||
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) | ||
require "fastlane/plugin/copy/version" | ||
require "fastlane/plugin/file_manager/version" | ||
|
||
Gem::Specification.new do |spec| | ||
spec.name = "fastlane-plugin-copy" | ||
spec.version = Fastlane::Copy::VERSION | ||
spec.name = "fastlane-plugin-file_manager" | ||
spec.version = Fastlane::FileManager::VERSION | ||
spec.author = "Jason Nam" | ||
spec.email = "[email protected]" | ||
|
||
spec.summary = "Copy file" | ||
spec.homepage = "https://github.com/jasonnam/fastlane-plugin-copy" | ||
spec.summary = "Copy and remove files" | ||
spec.homepage = "https://github.com/jasonnam/fastlane-plugin-file_manager" | ||
spec.license = "MIT" | ||
|
||
spec.files = Dir["lib/**/*"] + %w(README.md LICENSE) | ||
spec.test_files = spec.files.grep(%r{^(test|spec|features)/}) | ||
spec.require_paths = ["lib"] | ||
|
||
# Don"t add a dependency to fastlane or fastlane_re | ||
# since this would cause a circular dependency | ||
|
||
# spec.add_dependency "your-dependency", "~> 1.0.0" | ||
|
||
spec.add_development_dependency("pry") | ||
spec.add_development_dependency("bundler") | ||
spec.add_development_dependency("rspec") | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
lane :test do | ||
copy( | ||
source: "test.rb", | ||
destination: "lib" | ||
) | ||
copy_files(source: "test.rb", destination: "lib") | ||
remove_files(path: "test.rb") | ||
end |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 3 additions & 4 deletions
7
...stlane/plugin/copy/actions/copy_action.rb → ...file_manager/actions/copy_files_action.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
lib/fastlane/plugin/file_manager/actions/remove_files_action.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
require "fastlane/action" | ||
|
||
module Fastlane | ||
module Actions | ||
class RemoveFilesAction < Action | ||
def self.run(params) | ||
Actions.sh("rm", "-rf", params[:path]) | ||
end | ||
|
||
def self.description | ||
"Remove files" | ||
end | ||
|
||
def self.authors | ||
["Jason Nam"] | ||
end | ||
|
||
def self.available_options | ||
[ | ||
FastlaneCore::ConfigItem.new(key: :path, | ||
short_option: "-p", | ||
description: "Path for files to remove", | ||
optional: false, | ||
type: String) | ||
] | ||
end | ||
|
||
def self.is_supported?(platform) | ||
true | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
module Fastlane | ||
module FileManager | ||
VERSION = "0.2.0" | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
describe Fastlane::Actions::CopyAction do | ||
describe Fastlane::Actions::CopyFilesAction do | ||
describe "#run" do | ||
it "executes cp command with source and destination" do | ||
expect(Fastlane::Actions).to receive(:sh).with("cp", "test.rb", "lib") | ||
|
||
Fastlane::Actions::CopyAction.run(source: "test.rb", destination: "lib") | ||
Fastlane::Actions::CopyFilesAction.run(source: "test.rb", destination: "lib") | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
describe Fastlane::Actions::RemoveFilesAction do | ||
describe "#run" do | ||
it "executes rm command with path" do | ||
expect(Fastlane::Actions).to receive(:sh).with("rm", "-rf", "test.rb") | ||
|
||
Fastlane::Actions::RemoveFilesAction.run(path: "test.rb") | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters