Class: Gitlab::Checks::ProjectCreated
- Inherits:
-
PostPushMessage
- Object
- PostPushMessage
- Gitlab::Checks::ProjectCreated
- Defined in:
- lib/gitlab/checks/project_created.rb
Constant Summary collapse
- PROJECT_CREATED =
"project_created"
Class Method Summary collapse
-
.legacy_message_key(user, repository) ⇒ Object
TODO: Remove in the next release gitlab.com/gitlab-org/gitlab/-/issues/292030.
- .message_key(user, repository) ⇒ Object
Instance Method Summary collapse
Methods inherited from PostPushMessage
#add_message, fetch_message, #initialize
Constructor Details
This class inherits a constructor from Gitlab::Checks::PostPushMessage
Class Method Details
.legacy_message_key(user, repository) ⇒ Object
TODO: Remove in the next release gitlab.com/gitlab-org/gitlab/-/issues/292030
30 31 32 33 34 |
# File 'lib/gitlab/checks/project_created.rb', line 30 def self.(user, repository) return unless repository.project "#{PROJECT_CREATED}:#{user.id}:#{repository.project.id}" end |
.message_key(user, repository) ⇒ Object
24 25 26 |
# File 'lib/gitlab/checks/project_created.rb', line 24 def self.(user, repository) "#{PROJECT_CREATED}:#{user.id}:#{repository.gl_repository}" end |
Instance Method Details
#message ⇒ Object
8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/gitlab/checks/project_created.rb', line 8 def <<~MESSAGE The private project #{project.full_path} was successfully created. To configure the remote, run: git remote add origin #{url_to_repo} To view the project, visit: #{project_url} MESSAGE end |