parent
db1cc72b8c
commit
982ea3322c
@ -0,0 +1,2 @@
|
||||
---
|
||||
BUNDLE_PATH: "vendor/bundle"
|
@ -0,0 +1,34 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
source "https://rubygems.org"
|
||||
|
||||
git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
|
||||
|
||||
# gem "rails"
|
||||
|
||||
gem "sinatra", "~> 4.1"
|
||||
|
||||
gem "shotgun", "~> 0.9.2"
|
||||
|
||||
|
||||
gem "sqlite", "~> 1.0"
|
||||
|
||||
gem "inifile", "~> 3.0"
|
||||
|
||||
gem "carrierwave", "~> 3.1"
|
||||
|
||||
gem "data_mapper", "~> 1.2"
|
||||
|
||||
gem "json", "~> 1.8"
|
||||
|
||||
gem "stringio", "~> 3.1"
|
||||
|
||||
gem "puma", "~> 6.6"
|
||||
|
||||
gem "rackup", "~> 2.2"
|
||||
|
||||
gem "sqlite3", "~> 2.5"
|
||||
|
||||
gem "rugged", "~> 1.9"
|
||||
|
||||
gem "sequel", "~> 5.89"
|
@ -0,0 +1,187 @@
|
||||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
activemodel (8.0.1)
|
||||
activesupport (= 8.0.1)
|
||||
activesupport (8.0.1)
|
||||
base64
|
||||
benchmark (>= 0.3)
|
||||
bigdecimal
|
||||
concurrent-ruby (~> 1.0, >= 1.3.1)
|
||||
connection_pool (>= 2.2.5)
|
||||
drb
|
||||
i18n (>= 1.6, < 2)
|
||||
logger (>= 1.4.2)
|
||||
minitest (>= 5.1)
|
||||
securerandom (>= 0.3)
|
||||
tzinfo (~> 2.0, >= 2.0.5)
|
||||
uri (>= 0.13.1)
|
||||
addressable (2.8.7)
|
||||
public_suffix (>= 2.0.2, < 7.0)
|
||||
base64 (0.2.0)
|
||||
bcrypt (3.1.20)
|
||||
bcrypt-ruby (3.1.5)
|
||||
bcrypt (>= 3.1.3)
|
||||
benchmark (0.4.0)
|
||||
bigdecimal (3.1.9)
|
||||
carrierwave (3.1.1)
|
||||
activemodel (>= 6.0.0)
|
||||
activesupport (>= 6.0.0)
|
||||
addressable (~> 2.6)
|
||||
image_processing (~> 1.1)
|
||||
marcel (~> 1.0.0)
|
||||
ssrf_filter (~> 1.0)
|
||||
concurrent-ruby (1.3.5)
|
||||
connection_pool (2.5.0)
|
||||
data_mapper (1.2.0)
|
||||
dm-aggregates (~> 1.2.0)
|
||||
dm-constraints (~> 1.2.0)
|
||||
dm-core (~> 1.2.0)
|
||||
dm-migrations (~> 1.2.0)
|
||||
dm-serializer (~> 1.2.0)
|
||||
dm-timestamps (~> 1.2.0)
|
||||
dm-transactions (~> 1.2.0)
|
||||
dm-types (~> 1.2.0)
|
||||
dm-validations (~> 1.2.0)
|
||||
dm-aggregates (1.2.0)
|
||||
dm-core (~> 1.2.0)
|
||||
dm-constraints (1.2.0)
|
||||
dm-core (~> 1.2.0)
|
||||
dm-core (1.2.1)
|
||||
addressable (~> 2.3)
|
||||
dm-migrations (1.2.0)
|
||||
dm-core (~> 1.2.0)
|
||||
dm-serializer (1.2.2)
|
||||
dm-core (~> 1.2.0)
|
||||
fastercsv (~> 1.5)
|
||||
json (~> 1.6)
|
||||
json_pure (~> 1.6)
|
||||
multi_json (~> 1.0)
|
||||
dm-timestamps (1.2.0)
|
||||
dm-core (~> 1.2.0)
|
||||
dm-transactions (1.2.0)
|
||||
dm-core (~> 1.2.0)
|
||||
dm-types (1.2.2)
|
||||
bcrypt-ruby (~> 3.0)
|
||||
dm-core (~> 1.2.0)
|
||||
fastercsv (~> 1.5)
|
||||
json (~> 1.6)
|
||||
multi_json (~> 1.0)
|
||||
stringex (~> 1.4)
|
||||
uuidtools (~> 2.1)
|
||||
dm-validations (1.2.0)
|
||||
dm-core (~> 1.2.0)
|
||||
drb (2.2.1)
|
||||
fastercsv (1.5.5)
|
||||
ffi (1.17.1)
|
||||
ffi (1.17.1-aarch64-linux-gnu)
|
||||
ffi (1.17.1-aarch64-linux-musl)
|
||||
ffi (1.17.1-arm-linux-gnu)
|
||||
ffi (1.17.1-arm-linux-musl)
|
||||
ffi (1.17.1-arm64-darwin)
|
||||
ffi (1.17.1-x86-linux-gnu)
|
||||
ffi (1.17.1-x86-linux-musl)
|
||||
ffi (1.17.1-x86_64-darwin)
|
||||
ffi (1.17.1-x86_64-linux-gnu)
|
||||
ffi (1.17.1-x86_64-linux-musl)
|
||||
i18n (1.14.7)
|
||||
concurrent-ruby (~> 1.0)
|
||||
image_processing (1.14.0)
|
||||
mini_magick (>= 4.9.5, < 6)
|
||||
ruby-vips (>= 2.0.17, < 3)
|
||||
inifile (3.0.0)
|
||||
json (1.8.6)
|
||||
json_pure (1.8.6)
|
||||
logger (1.6.6)
|
||||
marcel (1.0.4)
|
||||
mini_magick (5.1.2)
|
||||
benchmark
|
||||
logger
|
||||
mini_portile2 (2.8.8)
|
||||
minitest (5.25.4)
|
||||
multi_json (1.15.0)
|
||||
mustermann (3.0.3)
|
||||
ruby2_keywords (~> 0.0.1)
|
||||
nio4r (2.7.4)
|
||||
public_suffix (6.0.1)
|
||||
puma (6.6.0)
|
||||
nio4r (~> 2.0)
|
||||
rack (3.1.10)
|
||||
rack-protection (4.1.1)
|
||||
base64 (>= 0.1.0)
|
||||
logger (>= 1.6.0)
|
||||
rack (>= 3.0.0, < 4)
|
||||
rack-session (2.1.0)
|
||||
base64 (>= 0.1.0)
|
||||
rack (>= 3.0.0)
|
||||
rackup (2.2.1)
|
||||
rack (>= 3)
|
||||
ruby-vips (2.2.3)
|
||||
ffi (~> 1.12)
|
||||
logger
|
||||
ruby2_keywords (0.0.5)
|
||||
rugged (1.9.0)
|
||||
securerandom (0.4.1)
|
||||
sequel (5.89.0)
|
||||
bigdecimal
|
||||
shotgun (0.9.2)
|
||||
rack (>= 1.0)
|
||||
sinatra (4.1.1)
|
||||
logger (>= 1.6.0)
|
||||
mustermann (~> 3.0)
|
||||
rack (>= 3.0.0, < 4)
|
||||
rack-protection (= 4.1.1)
|
||||
rack-session (>= 2.0.0, < 3)
|
||||
tilt (~> 2.0)
|
||||
sqlite (1.0.2)
|
||||
sqlite3 (2.5.0)
|
||||
mini_portile2 (~> 2.8.0)
|
||||
sqlite3 (2.5.0-aarch64-linux-gnu)
|
||||
sqlite3 (2.5.0-aarch64-linux-musl)
|
||||
sqlite3 (2.5.0-arm-linux-gnu)
|
||||
sqlite3 (2.5.0-arm-linux-musl)
|
||||
sqlite3 (2.5.0-arm64-darwin)
|
||||
sqlite3 (2.5.0-x86-linux-gnu)
|
||||
sqlite3 (2.5.0-x86-linux-musl)
|
||||
sqlite3 (2.5.0-x86_64-darwin)
|
||||
sqlite3 (2.5.0-x86_64-linux-gnu)
|
||||
sqlite3 (2.5.0-x86_64-linux-musl)
|
||||
ssrf_filter (1.2.0)
|
||||
stringex (1.5.1)
|
||||
stringio (3.1.3)
|
||||
tilt (2.6.0)
|
||||
tzinfo (2.0.6)
|
||||
concurrent-ruby (~> 1.0)
|
||||
uri (1.0.2)
|
||||
uuidtools (2.2.0)
|
||||
|
||||
PLATFORMS
|
||||
aarch64-linux-gnu
|
||||
aarch64-linux-musl
|
||||
arm-linux-gnu
|
||||
arm-linux-musl
|
||||
arm64-darwin
|
||||
ruby
|
||||
x86-linux-gnu
|
||||
x86-linux-musl
|
||||
x86_64-darwin
|
||||
x86_64-linux-gnu
|
||||
x86_64-linux-musl
|
||||
|
||||
DEPENDENCIES
|
||||
carrierwave (~> 3.1)
|
||||
data_mapper (~> 1.2)
|
||||
inifile (~> 3.0)
|
||||
json (~> 1.8)
|
||||
puma (~> 6.6)
|
||||
rackup (~> 2.2)
|
||||
rugged (~> 1.9)
|
||||
sequel (~> 5.89)
|
||||
shotgun (~> 0.9.2)
|
||||
sinatra (~> 4.1)
|
||||
sqlite (~> 1.0)
|
||||
sqlite3 (~> 2.5)
|
||||
stringio (~> 3.1)
|
||||
|
||||
BUNDLED WITH
|
||||
2.6.3
|
@ -1,3 +1,11 @@
|
||||
# mock-gui
|
||||
## Запуск
|
||||
|
||||
Система управления сборкой rpm пакетов на базе mock+git
|
||||
```
|
||||
bundle exec ruby app.rb
|
||||
```
|
||||
|
||||
## Подготовка базы данных
|
||||
|
||||
```
|
||||
bundle exec sequel -m db/migrations sqlite://db/workbase.sqlite3
|
||||
```
|
@ -0,0 +1,41 @@
|
||||
require "inifile"
|
||||
|
||||
class IniConfig
|
||||
attr :path
|
||||
|
||||
def initialize(in_path = "config.ini")
|
||||
@path = in_path
|
||||
@config = {}
|
||||
parse_ini
|
||||
end
|
||||
|
||||
def parse_ini()
|
||||
return if path.nil?
|
||||
return unless File.exist? path
|
||||
@config = IniFile.load(path)
|
||||
end
|
||||
|
||||
def get_port()
|
||||
unless @config["server"]["port"].nil?
|
||||
@config["server"]["port"].to_i
|
||||
else
|
||||
8080
|
||||
end
|
||||
end
|
||||
|
||||
def get_repo()
|
||||
unless @config["repo"]["repo"].nil?
|
||||
@config["repo"]["repo"].to_s
|
||||
else
|
||||
"repo"
|
||||
end
|
||||
end
|
||||
|
||||
def get_db()
|
||||
unless @config["server"]["db"].nil?
|
||||
@config["server"]["db"].to_s
|
||||
else
|
||||
"db"
|
||||
end
|
||||
end
|
||||
end
|
@ -0,0 +1,27 @@
|
||||
require "sequel"
|
||||
|
||||
cfg_internal = IniConfig.new()
|
||||
Sequel.connect(cfg_internal.get_db)
|
||||
|
||||
class Repos < Sequel::Model(:repos)
|
||||
end
|
||||
|
||||
class DBase
|
||||
attr :error, :last_id
|
||||
|
||||
def creategit(project_name, description)
|
||||
@error = nil
|
||||
data = Repos.where(reponame: project_name)
|
||||
unless data.nil?
|
||||
id = Repos.insert(reponame: project_name, descr: description, public: 1)
|
||||
@last_id = id
|
||||
else
|
||||
@error = "Данный репозиторий уже существует"
|
||||
end
|
||||
@error
|
||||
end
|
||||
|
||||
def get_repo_info_by_name(repo_name)
|
||||
Repos.where(reponame: repo_name)
|
||||
end
|
||||
end
|
@ -0,0 +1,6 @@
|
||||
[server]
|
||||
port = 8081
|
||||
db = "sqlite://db/workbase.sqlite3"
|
||||
|
||||
[repo]
|
||||
repo = "repo"
|
@ -0,0 +1,66 @@
|
||||
require "sequel"
|
||||
|
||||
Sequel.migration do
|
||||
change do
|
||||
create_table(:repos) do
|
||||
primary_key :id
|
||||
String :reponame, :null => false, :unique => true
|
||||
String :descr, text: true
|
||||
Datetime :create_at, default: Sequel.lit("CURRENT_TIMESTAMP")
|
||||
Integer :public
|
||||
end
|
||||
|
||||
create_table(:projects) do
|
||||
primary_key :id
|
||||
String :projname
|
||||
String :descr, text: true
|
||||
Datetime :create_at, default: Sequel.lit("CURRENT_TIMESTAMP")
|
||||
end
|
||||
|
||||
create_table(:repos_projects) do
|
||||
foreign_key :proj_id, :projects, :key => :id
|
||||
foreign_key :repo_id, :repos, :key => :id
|
||||
primary_key [:proj_id, :repo_id]
|
||||
end
|
||||
|
||||
create_table(:recips) do
|
||||
primary_key :id
|
||||
String :content, text: true
|
||||
String :filepath, text: true
|
||||
String :desct, text: true
|
||||
Datetime :create_at, default: Sequel.lit("CURRENT_TIMESTAMP")
|
||||
end
|
||||
|
||||
create_table(:repos_recips) do
|
||||
foreign_key :repo_id, :repos, :key => :id
|
||||
foreign_key :recip_id, :recips, :key => :id
|
||||
primary_key [:recip_id, :repo_id]
|
||||
end
|
||||
|
||||
create_table(:rpms) do
|
||||
primary_key :id
|
||||
String :savepath, text: true
|
||||
String :rpmname, text: true
|
||||
Integer :sign
|
||||
String :signpath, text: true
|
||||
foreign_key :repo_id, :repos, :key => :id
|
||||
end
|
||||
|
||||
create_table(:buildtask) do
|
||||
primary_key :id
|
||||
foreign_key :repo_id, :repos, :key => :id
|
||||
foreign_key :proj_id, :projects, :key => :id
|
||||
Datetime :create_at, default: Sequel.lit("CURRENT_TIMESTAMP")
|
||||
String :signpath, text: true
|
||||
String :logpath, text: true
|
||||
Integer :result
|
||||
String :errlogpath, text: true
|
||||
end
|
||||
|
||||
create_table(:build_rpm) do
|
||||
foreign_key :build_id, :buildtask, :key => :id
|
||||
foreign_key :rpm_id, :rpms, :key => :id
|
||||
primary_key [:build_id, :rpm_id]
|
||||
end
|
||||
end
|
||||
end
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -0,0 +1,57 @@
|
||||
.bs-icon {
|
||||
--bs-icon-size: .75rem;
|
||||
display: flex;
|
||||
flex-shrink: 0;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: var(--bs-icon-size);
|
||||
width: calc(var(--bs-icon-size) * 2);
|
||||
height: calc(var(--bs-icon-size) * 2);
|
||||
color: var(--bs-primary);
|
||||
}
|
||||
|
||||
.bs-icon-xs {
|
||||
--bs-icon-size: 1rem;
|
||||
width: calc(var(--bs-icon-size) * 1.5);
|
||||
height: calc(var(--bs-icon-size) * 1.5);
|
||||
}
|
||||
|
||||
.bs-icon-sm {
|
||||
--bs-icon-size: 1rem;
|
||||
}
|
||||
|
||||
.bs-icon-md {
|
||||
--bs-icon-size: 1.5rem;
|
||||
}
|
||||
|
||||
.bs-icon-lg {
|
||||
--bs-icon-size: 2rem;
|
||||
}
|
||||
|
||||
.bs-icon-xl {
|
||||
--bs-icon-size: 2.5rem;
|
||||
}
|
||||
|
||||
.bs-icon.bs-icon-primary {
|
||||
color: var(--bs-white);
|
||||
background: var(--bs-primary);
|
||||
}
|
||||
|
||||
.bs-icon.bs-icon-primary-light {
|
||||
color: var(--bs-primary);
|
||||
background: rgba(var(--bs-primary-rgb), .2);
|
||||
}
|
||||
|
||||
.bs-icon.bs-icon-semi-white {
|
||||
color: var(--bs-primary);
|
||||
background: rgba(255, 255, 255, .5);
|
||||
}
|
||||
|
||||
.bs-icon.bs-icon-rounded {
|
||||
border-radius: .5rem;
|
||||
}
|
||||
|
||||
.bs-icon.bs-icon-circle {
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
@ -0,0 +1 @@
|
||||
.bs-icon{--bs-icon-size:.75rem;display:flex;flex-shrink:0;justify-content:center;align-items:center;font-size:var(--bs-icon-size);width:calc(var(--bs-icon-size) * 2);height:calc(var(--bs-icon-size) * 2);color:var(--bs-primary)}.bs-icon-xs{--bs-icon-size:1rem;width:calc(var(--bs-icon-size) * 1.5);height:calc(var(--bs-icon-size) * 1.5)}.bs-icon-sm{--bs-icon-size:1rem}.bs-icon-md{--bs-icon-size:1.5rem}.bs-icon-lg{--bs-icon-size:2rem}.bs-icon-xl{--bs-icon-size:2.5rem}.bs-icon.bs-icon-primary{color:var(--bs-white);background:var(--bs-primary)}.bs-icon.bs-icon-primary-light{color:var(--bs-primary);background:rgba(var(--bs-primary-rgb),.2)}.bs-icon.bs-icon-semi-white{color:var(--bs-primary);background:rgba(255,255,255,.5)}.bs-icon.bs-icon-rounded{border-radius:.5rem}.bs-icon.bs-icon-circle{border-radius:50%}
|
@ -0,0 +1,22 @@
|
||||
<div class="container">
|
||||
<div style="padding-top: 45px;"></div>
|
||||
</div>
|
||||
<footer class="text-center bg-dark">
|
||||
<div class="container text-white py-4 py-lg-5">
|
||||
<ul class="list-inline">
|
||||
<li class="list-inline-item me-4"><a class="link-light" href="https://brepo.ru">Документация</a></li>
|
||||
<li class="list-inline-item me-4"><a class="link-light" href="https://dev.brepo.ru">Разработка</a></li>
|
||||
<li class="list-inline-item"><a class="link-light" href="https://hestiadocs.brepo.ru">Партнеры</a></li>
|
||||
</ul>
|
||||
<ul class="list-inline">
|
||||
<li class="list-inline-item me-4"><a href="https://dev.brepo.ru"><svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" fill="currentColor" viewBox="0 0 16 16" class="bi bi-github text-light">
|
||||
<path d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.012 8.012 0 0 0 16 8c0-4.42-3.58-8-8-8z"></path>
|
||||
</svg></a></li>
|
||||
</ul>
|
||||
<p class="text-muted mb-0">Copyright © 2025 BayRepo</p>
|
||||
</div>
|
||||
</footer>
|
||||
<script src="/assets/bootstrap/js/bootstrap.min.js"></script>
|
||||
</body>
|
||||
|
||||
</html>
|
@ -0,0 +1,33 @@
|
||||
<%= erb :header %>
|
||||
<div class="container py-4 py-xl-5">
|
||||
<div class="row mb-5">
|
||||
<div class="col-md-8 col-xl-6 text-center mx-auto">
|
||||
<h2>git проекты</h2>
|
||||
<p class="w-lg-50">Страница управления git проектами</p>
|
||||
<div>
|
||||
<div class="px-3"><a href="/gitcreate"><svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" fill="currentColor" viewBox="0 0 16 16" class="bi bi-plus-circle text-primary" style="font-size: 29px;">
|
||||
<path d="M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14zm0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16z"></path>
|
||||
<path d="M8 4a.5.5 0 0 1 .5.5v3h3a.5.5 0 0 1 0 1h-3v3a.5.5 0 0 1-1 0v-3h-3a.5.5 0 0 1 0-1h3v-3A.5.5 0 0 1 8 4z"></path>
|
||||
</svg> Добавить репозиторий</a></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row row-cols-1 row-cols-md-2 row-cols-xl-3">
|
||||
<% @repo_data.each do |item| %>
|
||||
<div class="col">
|
||||
<div class="d-flex p-3">
|
||||
<div class="bs-icon-sm bs-icon-rounded bs-icon-primary d-flex flex-shrink-0 justify-content-center align-items-center d-inline-block bs-icon sm"><svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" fill="currentColor" viewBox="0 0 16 16" class="bi bi-git">
|
||||
<path d="M15.698 7.287 8.712.302a1.03 1.03 0 0 0-1.457 0l-1.45 1.45 1.84 1.84a1.223 1.223 0 0 1 1.55 1.56l1.773 1.774a1.224 1.224 0 0 1 1.267 2.025 1.226 1.226 0 0 1-2.002-1.334L8.58 5.963v4.353a1.226 1.226 0 1 1-1.008-.036V5.887a1.226 1.226 0 0 1-.666-1.608L5.093 2.465l-4.79 4.79a1.03 1.03 0 0 0 0 1.457l6.986 6.986a1.03 1.03 0 0 0 1.457 0l6.953-6.953a1.031 1.031 0 0 0 0-1.457"></path>
|
||||
</svg></div>
|
||||
<div class="px-2">
|
||||
<h5 class="mb-0 mt-1"><%= item[:reponame] %></h5>
|
||||
</div>
|
||||
<div class="px-3"><a class="px-3" href="/repos/<%= ERB::Util.url_encode(item[:reponame]) %>"><svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" fill="currentColor" viewBox="0 0 16 16" class="bi bi-arrow-right-short" style="font-size: 41px;">
|
||||
<path fill-rule="evenodd" d="M4 8a.5.5 0 0 1 .5-.5h5.793L8.146 5.354a.5.5 0 1 1 .708-.708l3 3a.5.5 0 0 1 0 .708l-3 3a.5.5 0 0 1-.708-.708L10.293 8.5H4.5A.5.5 0 0 1 4 8z"></path>
|
||||
</svg></a></div>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
<%= erb :footer %>
|
@ -0,0 +1,22 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
|
||||
<title><%= @page_name %></title>
|
||||
<link rel="stylesheet" href="/assets/bootstrap/css/bootstrap.min.css">
|
||||
<link rel="stylesheet" href="/assets/css/Footer-Dark-icons.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="row text-center">
|
||||
<div class="col-md-12 align-self-center" style="background: #b6cff4;border-radius: 13px;">
|
||||
<h2 class="text-center" style="color: rgb(44,85,128);"><%= @page_name %></h2>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container">
|
||||
<div style="padding-top: 45px;"></div>
|
||||
</div>
|
@ -0,0 +1,16 @@
|
||||
<%= erb :header %>
|
||||
<% unless @error_data.nil? %>
|
||||
<div class="container">
|
||||
<div class="alert alert-warning alert-dismissible fade show" role="alert"><span><%= @error_data %></span><button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Закрыть"></button></div>
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="container">
|
||||
<form method="post">
|
||||
<label class="form-label">Название git репозитория, без пробелов, все extra символы (не входящие в диапазон a-z,A-Z,0-9,_) будут преобразованы в подчеркивание</label>
|
||||
<input class="form-control border-primary" type="text" name="gitname" id="gitname" required>
|
||||
<label class="form-label">Описание репозитория</label>
|
||||
<textarea class="form-control border-primary" name="gitdescr" id="gitdescr"></textarea>
|
||||
<div class="text-end" style="padding-top: 45px;"><button class="btn btn-primary" type="submit">Создать</button></div>
|
||||
</form>
|
||||
</div>
|
||||
<%= erb :footer %>
|
@ -0,0 +1,18 @@
|
||||
<%= erb :header %>
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-4"></div>
|
||||
<div class="col-md-4">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="mb-0">404</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<p class="card-text">Страница не найдена, возможно вы ошиблись символом в строке запроса. </p><a href="<%= @req_referer %>">Вернуться на предыдущую страницу</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4"></div>
|
||||
</div>
|
||||
</div>
|
||||
<%= erb :footer %>
|
@ -0,0 +1,18 @@
|
||||
<%= erb :header %>
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-4"></div>
|
||||
<div class="col-md-4">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="mb-0"><%= @status_err %></h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<p class="card-text"><%= @error_msg %> </p><a href="<%= @req_referer %>">Вернуться на предыдущую страницу</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4"></div>
|
||||
</div>
|
||||
</div>
|
||||
<%= erb :footer %>
|
Loading…
Reference in new issue