Skip to content

Commit 5d7dee9

Browse files
authored
Merge pull request progit#3 from Morganov/translate/readme
Дададзены переклад README і LICENSE, адноулены файлы сборкі, выдалены састарэлыя файлы
2 parents a0f5bb2 + fcd967e commit 5d7dee9

File tree

15 files changed

+288
-250
lines changed

15 files changed

+288
-250
lines changed

.github/workflows/pr-build.yml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,13 @@ jobs:
88
build:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v2
11+
- uses: actions/checkout@v3
1212

13-
- name: Download bootstrap file
14-
run: wget https://raw.githubusercontent.com/progit/progit2-pub/master/bootstrap.sh
15-
- name: Run bootstrap
16-
run: sh bootstrap.sh
17-
- name: Set up Ruby
18-
uses: ruby/setup-ruby@v1
19-
with:
20-
ruby-version: 2.7
21-
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
13+
- name: Set up Ruby
14+
uses: ruby/setup-ruby@v1
15+
with:
16+
ruby-version: 2.7
17+
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
2218

23-
- name: Build book
24-
run: bundle exec rake book:build_action
19+
- name: Build Book
20+
run: bundle exec rake book:build
Lines changed: 30 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,41 @@
1-
name: Release on push to main
1+
name: Release from master
22

33
on:
44
push:
5-
branches: [ main, master ]
5+
branches: [ master ]
6+
7+
workflow_dispatch:
68

79
jobs:
810
release:
911
runs-on: ubuntu-latest
1012
steps:
11-
- uses: actions/checkout@v2
12-
with:
13-
fetch-depth: 0
14-
- name: get bootstrap file
15-
run: wget https://raw.githubusercontent.com/progit/progit2-pub/master/bootstrap.sh
16-
- name: run bootstrap
17-
run: sh bootstrap.sh
18-
- name: Compute tag name
19-
id: compute-tag
20-
run: |
21-
echo Computing next tag number
22-
LASTPATCH=$(git describe --tags | cut -d- -f1 | cut -d. -f3)
23-
PATCH=$(($LASTPATCH+1))
24-
echo "::set-output name=tagname::2.1.${PATCH}"
25-
echo "::set-output name=branch::${GITHUB_REF#refs/heads/}"
13+
- uses: actions/checkout@v3
14+
with:
15+
fetch-depth: 0
16+
17+
- name: Compute tag name
18+
id: compute-tag
19+
run: |
20+
echo "Computing next tag number"
21+
LASTPATCH=$(git describe --tags | cut -d- -f1 | cut -d. -f3)
22+
PATCH=$(($LASTPATCH+1))
23+
echo "New tag name: 2.1.${PATCH}"
24+
echo "::set-output name=tagname::2.1.${PATCH}"
2625
27-
- name: Set up Ruby
28-
uses: ruby/setup-ruby@v1
29-
with:
30-
ruby-version: 2.7
31-
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
26+
- name: Set up Ruby
27+
uses: ruby/setup-ruby@v1
28+
with:
29+
ruby-version: 2.7
30+
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
3231

33-
- name: Build release assets
34-
run: bundle exec rake book:build_action
32+
- name: Build release assets
33+
run: bundle exec rake book:build
3534

36-
- name: Create release
37-
uses: ncipollo/release-action@v1
38-
with:
39-
token: ${{ secrets.GITHUB_TOKEN }}
40-
tag: ${{ steps.compute-tag.outputs.tagname }}
41-
commit: ${{ steps.compute-tag.outputs.branch }}
42-
artifacts: './progit.epub,./progit.mobi,./progit.pdf,./progit.html'
35+
- name: Create Release
36+
uses: ncipollo/release-action@v1
37+
with:
38+
token: ${{ secrets.GITHUB_TOKEN }}
39+
tag: ${{ steps.compute-tag.outputs.tagname }}
40+
commit: master
41+
artifacts: './progit.epub,./progit.mobi,./progit.pdf,./progit.html'

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
output
22
.DS_Store
3+
.vscode
4+
.bundle
35

46
# build artifacts
57
Gemfile.lock

.travis.yml

Lines changed: 0 additions & 35 deletions
This file was deleted.

Gemfile

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
source 'https://rubygems.org'
22

3-
gem 'rake', '13.0.3'
4-
gem 'asciidoctor', '2.0.12'
3+
gem 'rake', '13.0.6'
4+
gem 'asciidoctor', '2.0.17'
55

6-
gem 'json', '2.5.1'
7-
gem 'awesome_print', '1.8.0'
6+
gem 'json', '2.6.2'
7+
gem 'awesome_print', '1.9.2'
88

9-
gem 'asciidoctor-epub3', '1.5.0.alpha.19'
10-
gem 'asciidoctor-pdf', '1.5.4'
9+
gem 'asciidoctor-epub3', '1.5.1'
10+
gem 'asciidoctor-pdf', '2.0.8'
1111

1212
gem 'coderay', '1.1.3'
13-
gem 'pygments.rb', '2.0.0'
13+
gem 'pygments.rb', '2.3.0'
1414
gem 'thread_safe', '0.3.6'
15-
gem 'epubcheck-ruby', '4.2.4.0'
16-
gem 'html-proofer', '3.18.5'
15+
gem 'epubcheck-ruby', '4.2.6.0'
16+
gem 'html-proofer', '3.19.4'

LICENSE.asc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
2-
To view a copy of this license, visit https://creativecommons.org/licenses/by-nc-sa/3.0 or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
1+
Гэты твор распаўсюджваецца па вольнай ліцэнзіі Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
2+
Азнаёміцца з тэкстам ліцэнзіі вы можаце на сайце https://creativecommons.org/licenses/by-nc-sa/3.0/deed.be або па пошце, даслаўшы ліст у арганізацыю Creative Commons па адрасе: PO Box 1866, Mountain View, CA 94042, USA.

README.asc

Lines changed: 106 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,126 @@
1-
= Pro Git, Second Edition
1+
= Pro Git, Другое Выданне
22

3-
Welcome to the second edition of the Pro Git book.
3+
Вітаем у другім выданні кнігі Pro Git.
44

5-
You can find this book online at: https://git-scm.com/book
5+
Гэтую ж самую кнігу можна знайсці онлайн: https://git-scm.com/book
66

7-
Like the first edition, the second edition of Pro Git is open source under a Creative Commons license.
7+
Гэтае выданне, як і першае, з'яўляецца праектам з адкрытым зыходным кодам з ліцэнзіяй Creative Commons.
88
9-
A couple of things have changed since open sourcing the first edition.
10-
For one, we've moved from Markdown to the amazing AsciiDoc format for the text of the book; here's an https://asciidoctor.org/docs/asciidoc-syntax-quick-reference/[AsciiDoc quick reference].
9+
З моманту публікацыі першага выдання шмат што змянілася.
10+
Па-першае, мы перайшлі з Markdown на AsciiDoc -- вось кароткі даведнік па сінтаксісе https://asciidoctor.org/docs/asciidoc-syntax-quick-reference/[AsciiDoc].
1111
12-
We've also moved to keeping the translations in separate repositories rather than subdirectories of the English repository.
13-
See link:TRANSLATING.md[the translating document] for more information.
12+
Па-другое, пераклады на іншыя мовы перанесены ў асобныя рэпазітары.
13+
Падрабязна у пункце пра пераклады.
1414
15-
== How To Generate the Book
15+
== Як прыняць удзел
1616
17-
You can generate the e-book files manually with Asciidoctor.
18-
We used to be able to build .mobi files (Kindle), but cannot do so now, see #1496 for more information.
19-
If you run the following you _may_ actually get HTML, Epub and PDF output files:
17+
Каб выправіць памылку або дадаць нешта новае ў гэты рэпазітар, вам трэба адкрыць запыт на зліццё (Pull Request) на GitHub.
18+
19+
Нягледзячы на тое, што ў ангельскай версіі просяць ўстрымацца ад стылістычных змен на вялікіх участках тэксту, гэты пераклад прафесійныя рэдактары не праглядалі, будзем рады вашым праўкам.
20+
21+
== Як сабраць кнігу
22+
23+
Ёсць два сбосабу атрымаць файл электроннай кнігі з гэтага коду.
24+
25+
Самы просты -- даручыць гэта нам.
26+
Робат рэагуе на змены ў ветцы `master` рэпазітара и аутаматычна збірае кнігу ва ўсіх фарматах.
27+
28+
Апошнюю зборку можна знайсці на старонцы https://git-scm.com/book/be/v2.
29+
30+
Іншы спосаб атрымаць кнігу -- сабраць яе самастойна з дапамогай Asciidoctor.
31+
Выкарыстоўваючы каманды ніжэй, вы зможаце атрымаць кнігу ў фарматах HTML, EPUB і PDF.
2032
2133
----
34+
$ bundle config set --local path '.bundle/vendor'
2235
$ bundle install
2336
$ bundle exec rake book:build
37+
Downloading locale attributes file...
38+
-- Saved at attributes-ru.adoc
2439
Converting to HTML...
2540
-- HTML output at progit.html
26-
Converting to EPub...
27-
-- Epub output at progit.epub
41+
Converting to EPUB...
42+
-- EPUB output at progit.epub
2843
Converting to PDF...
29-
-- PDF output at progit.pdf
44+
-- PDF output at progit.pdf
45+
Validating generated files...
46+
-- Validate HTML file progit.html
47+
Running ["ScriptCheck", "LinkCheck", "ImageCheck", "HtmlCheck"] on progit.html on *.html...
48+
49+
50+
Checking 89 external links...
51+
Ran on 1 file.
52+
53+
54+
HTML-Proofer finished successfully.
55+
-- Validate EPUB output file progit.epub
56+
Validating using EPUB version 3.2 rules.
57+
No errors or warnings detected.
58+
Messages: 0 fatals / 0 errors / 0 warnings / 0 infos
59+
60+
EPUBCheck completed
61+
----
62+
63+
Тут выкарыстоўваюцца праекты `asciidoctor`, `asciidoctor-pdf` и `asciidoctor-epub`.
64+
65+
Па змаўчанні, `bundle install` усталёўвае залежнасці глабальна у сістэму.
66+
Каб гэтага пазбегнуць, у прыкладзе вышэй менеджэр пакетаў дадаткова канфігуруецца перад усталяваннем залежнасцяў з дапамогай наступнай каманды:
67+
68+
----
69+
bundle config set --local path '.bundle/vendor'
70+
----
71+
72+
Таксама існуе магчымасць сабраць кнігу толькі ў адным з фарматаў.
73+
74+
Для генерацыі толькі HTML файла:
75+
76+
----
77+
bundle exec rake book:build_html
3078
----
3179
32-
== Signaling an Issue
80+
Для генерацыі толькі EPUB-файла:
81+
82+
----
83+
bundle exec rake book:build_epub
84+
----
85+
86+
Для генерацыі толькі PDF файла:
87+
88+
----
89+
bundle exec rake book:build_pdf
90+
----
91+
92+
Для валідацыі згенераваных файлаў прадугледжаны каманды праверкі.
93+
94+
Для праверкі HTML файла:
95+
96+
----
97+
bundle exec rake book:check_html
98+
----
99+
100+
Для праверкі EPUB-файла:
101+
102+
----
103+
bundle exec rake book:check_epub
104+
----
105+
106+
Звярніце ўвагу, што для запуску праверкі EPUB-файла патрабуецца наяўнасць усталяванага JRE.
107+
108+
== Пераклады
109+
110+
Пераклады на іншыя мовы горача вітаюцца, але апрацоўваюцца некалькі інакш, чым у першым выданні.
111+
Мы захоўваем кожны пераклад у асобным рэпазітары і аўтаматычна збіраем гатовыя файлы з дапамогай AsciiDoctor.
112+
Гэта было рэальна складаным у мінулым выданні.
113+
114+
Раз кожны пераклад захоўваецца ў сваім рэпазітары, зараз мы можам выбраць свайго каардынатара для кожнага з іх.
115+
Каманда Pro Git проста дадасць іх да сябе.
116+
Для аўтаматычнай зборкі рэпазітар павінен знаходзіцца ў каманды Pro Git https://github.com/progit[на GitHub].
33117
34-
Before signaling an issue, please check that there isn't already a similar one in the bug tracking system.
118+
== Ілюстрацыі
35119
36-
Also, if this issue has been spotted on the git-scm.com site, please cross-check that it is still present in this repo.
37-
The issue may have already been corrected, but the changes have not been deployed yet.
120+
Малюнкі гэтай кнігі былі створаны з дапамогай https://www.sketch.com/[Sketch 3], арыгінальны https://github.com/progit/progit2/blob/master/diagram-source/progit.sketch[файл] у фармаце sketchbook даступны ў ангельскай версіі кнігі.
38121
39-
== Contributing
122+
Даданне ілюстрацыі:
40123
41-
If you'd like to help out by making a change, take a look at the link:CONTRIBUTING.md[contributor's guide].
124+
. Дадайце старонку ў sketchbook; па-магчымасці старайцеся выкарыстоўваць убудаваныя сімвалы.
125+
. Дадайце «slice» на сваю старонку; назавіце яе таксама, як PNG файл, адносна каранёвай часткі зыходнага кода кнігі.
126+
. Пераканайцеся, што ў наладах экспарту выстаўлены трохразовы памер.

0 commit comments

Comments
 (0)