Skip to content

Commit e834109

Browse files
authored
Merge pull request #269 from hjwp/rename-17
Rename chapter 17
2 parents 4ef355a + 32dcd53 commit e834109

15 files changed

+36
-24
lines changed

.gitmodules

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
path = source/chapter_16_javascript/superlists
4242
url = [email protected]:hjwp/book-example.git
4343
[submodule "source/chapter_15/superlists"]
44-
path = source/chapter_deploying_validation/superlists
44+
path = source/chapter_17_second_deploy/superlists
4545
url = [email protected]:hjwp/book-example.git
4646
[submodule "source/chapter_16/superlists"]
4747
path = source/chapter_spiking_custom_auth/superlists

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,9 +127,9 @@ test_chapter_15_advanced_forms: chapter_15_advanced_forms.html $(TMPDIR) $(VENV)
127127
.PHONY: test_chapter_16_javascript
128128
test_chapter_16_javascript: chapter_16_javascript.html $(TMPDIR) $(VENV)/bin
129129
$(VENV)/bin/pytest -s --tb=short ./tests/test_chapter_16_javascript.py
130-
.PHONY: test_chapter_deploying_validation
131-
test_chapter_deploying_validation: chapter_deploying_validation.html $(TMPDIR) $(VENV)/bin
132-
$(VENV)/bin/pytest -s --tb=short ./tests/test_chapter_deploying_validation.py
130+
.PHONY: test_chapter_17_second_deploy
131+
test_chapter_17_second_deploy: chapter_17_second_deploy.html $(TMPDIR) $(VENV)/bin
132+
$(VENV)/bin/pytest -s --tb=short ./tests/test_chapter_17_second_deploy.py
133133
.PHONY: test_chapter_spiking_custom_auth
134134
test_chapter_spiking_custom_auth: chapter_spiking_custom_auth.html $(TMPDIR) $(VENV)/bin
135135
$(VENV)/bin/pytest -s --tb=short ./tests/test_chapter_spiking_custom_auth.py

appendix_IV_testing_migrations.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ An Attempted Deploy to Staging
2727

2828

2929
Here's what happened to me when I first tried to deploy our new validation
30-
constraints in <<chapter_deploying_validation>>:
30+
constraints in <<chapter_17_second_deploy>>:
3131

3232

3333
[role="skipme"]

appendix_github_links.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ Full List of Links for Each Chapter
3535
<<chapter_14_simple_form>>:: https://github.com/hjwp/book-example/tree/chapter_14_simple_form
3636
<<chapter_15_advanced_forms>>:: https://github.com/hjwp/book-example/tree/chapter_15_advanced_forms
3737
<<chapter_16_javascript>>:: https://github.com/hjwp/book-example/tree/chapter_16_javascript
38-
<<chapter_deploying_validation>>:: https://github.com/hjwp/book-example/tree/chapter_deploying_validation
38+
<<chapter_17_second_deploy>>:: https://github.com/hjwp/book-example/tree/chapter_17_second_deploy
3939
<<chapter_spiking_custom_auth>>:: https://github.com/hjwp/book-example/tree/chapter_spiking_custom_auth
4040
<<chapter_mocking>>:: https://github.com/hjwp/book-example/tree/chapter_mocking
4141
<<chapter_fixtures_and_wait_decorator>>:: https://github.com/hjwp/book-example/tree/chapter_fixtures_and_wait_decorator

atlas.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"chapter_14_simple_form.asciidoc",
2929
"chapter_15_advanced_forms.asciidoc",
3030
"chapter_16_javascript.asciidoc",
31-
"chapter_deploying_validation.asciidoc",
31+
"chapter_17_second_deploy.asciidoc",
3232
"part3.asciidoc",
3333
"chapter_spiking_custom_auth.asciidoc",
3434
"chapter_mocking.asciidoc",

book.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ include::chapter_13_database_layer_validation.asciidoc[]
3838
include::chapter_14_simple_form.asciidoc[]
3939
include::chapter_15_advanced_forms.asciidoc[]
4040
include::chapter_16_javascript.asciidoc[]
41-
include::chapter_deploying_validation.asciidoc[]
41+
include::chapter_17_second_deploy.asciidoc[]
4242

4343
include::part3.forbook.asciidoc[]
4444
include::chapter_spiking_custom_auth.asciidoc[]

chapter_15_advanced_forms.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ compatible.
349349
To fix this problem, we can just delete `src/db.sqlite3` and run the migration again.
350350
We can do this because the database on our laptop is only used for dev, so the data in it is not important.
351351

352-
In <chapter_deploying_validation>>, we'll deploy our new code to production,
352+
In <chapter_17_second_deploy>>, we'll deploy our new code to production,
353353
and discuss what to do if we run into migrations and data integrity issues at that point.
354354

355355
Now if we change our duplicates test to do a `.save` instead of a

chapter_deploying_validation.asciidoc renamed to chapter_17_second_deploy.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[[chapter_deploying_validation]]
1+
[[chapter_17_second_deploy]]
22
Deploying Our New Code
33
----------------------
44

preface.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ I've split this book into three parts.
189189
stage. I also introduce the Testing Goat.
190190

191191

192-
<<part2>> (Chapters pass:[<a data-type="xref" data-xrefstyle="select:labelnumber" href="#chapter_08_prettification">#chapter_08_prettification</a>–<a data-type="xref" data-xrefstyle="select:labelnumber" href="#chapter_deploying_validation">#chapter_deploying_validation</a>]): Web development essentials::
192+
<<part2>> (Chapters pass:[<a data-type="xref" data-xrefstyle="select:labelnumber" href="#chapter_08_prettification">#chapter_08_prettification</a>–<a data-type="xref" data-xrefstyle="select:labelnumber" href="#chapter_17_second_deploy">#chapter_17_second_deploy</a>]): Web development essentials::
193193
Covers some of the trickier but unavoidable aspects of web development, and
194194
shows how testing can help us with them: static files, deployment to
195195
production, form data validation, database migrations, and the dreaded

rename-chapter.sh

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,19 @@ set -o pipefail
55
OLD_CHAPTER=$1
66
NEW_NAME=$2
77

8-
git mv "$OLD_CHAPTER.asciidoc" "$NEW_NAME.asciidoc"
9-
mv "$OLD_CHAPTER.html" "$NEW_NAME.html" || touch "$NEW_NAME.html"
10-
git mv "tests/test_$OLD_CHAPTER.py" "tests/test_$NEW_NAME.py"
11-
12-
git mv "source/$OLD_CHAPTER" "source/$NEW_NAME"
13-
8+
# git mv "$OLD_CHAPTER.asciidoc" "$NEW_NAME.asciidoc"
9+
# mv "$OLD_CHAPTER.html" "$NEW_NAME.html" || touch "$NEW_NAME.html"
10+
#
11+
# if [ -e "tests/test_$OLD_CHAPTER.py" ]; then
12+
# git mv "tests/test_$OLD_CHAPTER.py" "tests/test_$NEW_NAME.py"
13+
# fi
14+
#
15+
# git mv "source/$OLD_CHAPTER" "source/$NEW_NAME"
16+
#
1417
cd "source/$NEW_NAME/superlists"
15-
git checkout "$OLD_CHAPTER"
16-
git checkout -b "$NEW_NAME"
18+
# git checkout "$OLD_CHAPTER"
19+
# git checkout -b "$NEW_NAME"
20+
git checkout "$NEW_NAME"
1721
git push -u local
1822
git push -u origin
1923
cd ../../..

0 commit comments

Comments
 (0)