Skip to content
This repository was archived by the owner on Jun 7, 2023. It is now read-only.

Commit a340ebc

Browse files
committed
Cleanup punctuation in init and remove cruft from template index.
1 parent 710ecd1 commit a340ebc

File tree

2 files changed

+9
-11
lines changed

2 files changed

+9
-11
lines changed

runestone/__main__.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,12 @@ def init():
1717
click.confirm("Do you want to proceed? ", abort=True, default=True)
1818
print("Next we need to gather a few pieces of information to create your configuration files")
1919
conf_dict['project_name'] = click.prompt("Project name: (one word, no spaces)")
20-
conf_dict['build_dir'] = click.prompt("path to build dir ", default="./build")
21-
conf_dict['login_req'] = click.prompt("require login ", default="false")
20+
while ' ' in conf_dict['project_name']:
21+
conf_dict['project_name'] = click.prompt("Project name: (one word, NO SPACES)")
22+
conf_dict['build_dir'] = click.prompt("Path to build dir ", default="./build")
23+
conf_dict['login_req'] = click.prompt("Require login ", default="false")
2224
conf_dict['master_url'] = click.prompt("URL for ajax server ", default="http://127.0.0.1:8000")
23-
conf_dict['author'] = click.prompt("your Name ", default=getpass.getuser())
25+
conf_dict['author'] = click.prompt("Your Name ", default=getpass.getuser())
2426
conf_dict['project_title'] = click.prompt("Title for this project ", default="Runestone Default")
2527
conf_dict['logging'] = click.prompt("Log student actions? ", type=bool, default=True)
2628
conf_dict['log_level'] = 10 if conf_dict['logging'] else 0

runestone/common/project_template/_sources/index.rst

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
=====================
32
This Is A New Project
43
=====================
@@ -15,7 +14,7 @@ This Is A New Project
1514
(e.g. "DataStructures/queues.rst").
1615
1716
SECTION 1: Introduction
18-
:::::::::::::::::::::::::::
17+
:::::::::::::::::::::::
1918

2019
Congratulations! If you can see this file you have probably successfully run the ``runestone init`` command. If you are looking at this as a source file you should now run ``runestone build`` to generate html files. Once you have run the build command you can run ``runestone serve`` and then view this in your browser at ``http://localhost:8000``
2120

@@ -25,7 +24,7 @@ The overview section, which follows is an ideal section to look at both online a
2524

2625

2726
SECTION 2: An Overview of the extensions
28-
:::::::::::::::::::::::::::::::::
27+
::::::::::::::::::::::::::::::::::::::::
2928

3029
.. toctree::
3130
:maxdepth: 2
@@ -34,11 +33,8 @@ SECTION 2: An Overview of the extensions
3433

3534

3635
SECTION 2: Add more stuff here
37-
:::::::::::::::::::::::::::::::::
36+
::::::::::::::::::::::::::::::
3837

3938
You can add more stuff here.
4039

41-
.. morecontent.rst
42-
.. words.rst
43-
.. somestuff.rst
44-
.. MoreThings/apples.rst
40+

0 commit comments

Comments
 (0)