Class: Fastlane::Actions::AddGitRemoteAction
- Inherits:
-
Action
- Object
- Action
- Fastlane::Actions::AddGitRemoteAction
- Defined in:
- lib/fastlane/plugin/menigit/actions/add_git_remote.rb
Class Method Summary collapse
- .authors ⇒ Object
- .available_options ⇒ Object
- .category ⇒ Object
- .description ⇒ Object
- .details ⇒ Object
- .example_code ⇒ Object
- .is_supported?(platform) ⇒ Boolean
- .run(options) ⇒ Object
Class Method Details
.authors ⇒ Object
54 55 56 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 54 def self. ["Marcin Stepnowski"] end |
.available_options ⇒ Object
25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 25 def self. [ FastlaneCore::ConfigItem.new(key: :remote, env_name: "FL_ADD_GIT_REMOTE_REMOTE", description: "Remote name", optional: false, type: String), FastlaneCore::ConfigItem.new(key: :path, env_name: "FL_ADD_GIT_REMOTE_PATH", description: "Path to repository. URL or SSH", optional: false, type: String) ] end |
.category ⇒ Object
46 47 48 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 46 def self.category :source_control end |
.description ⇒ Object
13 14 15 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 13 def self.description "This will add a remote repository" end |
.details ⇒ Object
17 18 19 20 21 22 23 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 17 def self.details [ "This will automatically add a remote repository, where:", "- `remote` is the remote name", "- `path` is the remote path (URL or SSH)" ].join("\n") end |
.example_code ⇒ Object
40 41 42 43 44 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 40 def self.example_code [ 'add_git_remote(remote: "origin", path: "https://github.com/meniga/menigit")' ] end |
.is_supported?(platform) ⇒ Boolean
50 51 52 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 50 def self.is_supported?(platform) true end |
.run(options) ⇒ Object
6 7 8 9 10 11 |
# File 'lib/fastlane/plugin/menigit/actions/add_git_remote.rb', line 6 def self.run() remote = [:remote] path = [:path] UI.("Adding remote #{remote} #{path} 🎯.") Actions.sh("git remote add #{remote.shellescape} #{path.shellescape}") end |