Class: Fastlane::Actions::SetGitConfigUserAction
- Inherits:
-
Action
- Object
- Action
- Fastlane::Actions::SetGitConfigUserAction
- Defined in:
- lib/fastlane/plugin/menigit/actions/set_git_config_user.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
59 60 61 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 59 def self. ["Marcin Stepnowski"] end |
.available_options ⇒ Object
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 29 def self. [ FastlaneCore::ConfigItem.new(key: :name, env_name: "FL_SET_GIT_CONFIG_USER_NAME", description: "User name", optional: false, type: String), FastlaneCore::ConfigItem.new(key: :email, env_name: "FL_SET_GIT_CONFIG_USER_EMAIL", description: "User email", optional: false, type: String) ] end |
.category ⇒ Object
51 52 53 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 51 def self.category :source_control end |
.description ⇒ Object
17 18 19 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 17 def self.description "This will set git config user" end |
.details ⇒ Object
21 22 23 24 25 26 27 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 21 def self.details [ "This will automatically set git config user, where:", "- `email` is the user email", "- `name` is the user name" ].join("\n") end |
.example_code ⇒ Object
45 46 47 48 49 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 45 def self.example_code [ 'set_git_config_user(name: "MenigaBuildsson", email: "[email protected]")' ] end |
.is_supported?(platform) ⇒ Boolean
55 56 57 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 55 def self.is_supported?(platform) true end |
.run(options) ⇒ Object
6 7 8 9 10 11 12 13 14 15 |
# File 'lib/fastlane/plugin/menigit/actions/set_git_config_user.rb', line 6 def self.run() name = [:name] email = [:email] UI.("Setting git config user.name to #{name} 🎯.") Actions.sh("git config user.name #{name.shellescape}") UI.("Setting git config user.email to #{email} 🎯.") Actions.sh("git config user.email #{email.shellescape}") end |