gitlabhq/app/views/projects/empty.html.haml

48 lines
1.6 KiB
Plaintext
Raw Normal View History

2012-01-18 00:19:57 +01:00
- if current_user.require_ssh_key?
2012-01-28 15:47:55 +01:00
.alert-message.block-message.error
%ul
%li You have no ssh keys added to your profile.
%li You wont be able to pull/push repository.
%li Visit profile → keys and add public key of every machine you want to use for work with gitlabhq.
2012-01-18 00:19:57 +01:00
2012-01-28 15:47:55 +01:00
.alert-message.block-message.error
%ul.unstyled.alert_holder
2012-01-28 15:47:55 +01:00
%li You should push repository to proceed.
%li After push you will be able to browse code, commits etc.
2012-01-18 00:19:57 +01:00
- bash_lexer = Pygments::Lexer[:bash]
%div.git-empty
%h3 Git global setup:
- setup_str = ["git config --global user.name \"#{current_user.name}\"",
2012-01-18 00:19:57 +01:00
"git config --global user.email \"#{current_user.email}\""].join("\n")
= preserve do
= raw bash_lexer.highlight(setup_str, lexer: 'bash', options: {encoding: 'utf-8'})
2012-01-18 00:19:57 +01:00
%br
%br
%h3 Create Repository
- repo_setup_str = ["mkdir #{@project.path}",
"cd #{@project.path}",
"git init",
2012-01-18 00:19:57 +01:00
"touch README",
"git add README",
"git commit -m 'first commit'",
"git remote add origin #{@project.url_to_repo}",
"git push -u origin master"].join("\n")
= preserve do
= raw bash_lexer.highlight(repo_setup_str)
2012-01-18 00:19:57 +01:00
%br
%br
%h3 Existing Git Repo?
- exist_repo_setup_str = ["cd existing_git_repo",
"git remote add origin #{@project.url_to_repo}",
"git push -u origin master"].join("\n")
= preserve do
= raw bash_lexer.highlight(exist_repo_setup_str)
- if can? current_user, :admin_project, @project
.alert-message.block-message.error.prepend-top-20
= link_to 'Remove project', @project, confirm: 'Are you sure?', method: :delete, class: "btn danger"