Skip to content

Commit 2128109

Browse files
author
Ware, Joseph (DLSLtd,RAL,LSCI)
committed
Merge commit '5294bde31ef4656077254f0ffd342991c6f7e615' into debug-services
2 parents d6515e5 + 5294bde commit 2128109

File tree

4 files changed

+7
-13
lines changed

4 files changed

+7
-13
lines changed

README.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,6 @@ It integrates the following tools:
3434

3535
You can see the template in action in the [example project](https://github.com/DiamondLightSource/python-copier-template-example). This is an up to date expansion of the template to illustrate how it looks with all the options enabled.
3636

37-
## Create a new project via Developer Portal
38-
39-
> [!NOTE]
40-
> Template creation from the developer portal is currently under construction, so these instructions do not work yet
41-
42-
Visit <https://dev-portal.diamond.ac.uk/create> and you will see a list of templates that you can create. Pick the one marked `Python Template` and fill in the details of the project.
43-
4437
## Create a new project from the commandline
4538

4639
You will need to `pip install copier` inside an activated `venv` from python3.11 or later, then you can create a new module via:

docs/tutorials/adopt-existing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ copier copy https://github.com/DiamondLightSource/python-copier-template.git --t
2222
git diff
2323
# Examine the changes, put back anything you want to keep
2424
git commit -m "Adopt python-copier-template 1.0.0"
25-
copier update /path/to/existing-project
25+
copier update /path/to/existing-project --trust
2626
git diff
2727
# Examine the changes, resolve any merge conflicts
2828
git commit -m "Update to python-copier-template x.x.x"

docs/tutorials/create-new.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,9 @@ $ git commit -m "Expand from python-copier-template x.x.x"
2525

2626
## Uploading to GitHub
2727

28-
You can now [create a new blank project on GitHub](https://github.com/new). Choose the same GitHub owner and repo name that you answered in the questions earlier. GitHub will now give you the commands needed to upload your repo from GitHub
28+
If the project is to be under the DiamondLightSource organisation, request a new repository in the [#github-requests Slack channel](https://diamondlightsource.slack.com/archives/C06A18ZPP44) with the given repo name, description and who to add as an owner in addition to yourself. This will be replaced by [a template in the developer-portal in future.](https://github.com/DiamondLightSource/python-copier-template/issues/274)
29+
30+
Else, you can now [create a new blank project on GitHub](https://github.com/new). Choose the same GitHub owner and repo name that you answered in the questions earlier. GitHub will now give you the commands needed to upload your repo from GitHub.
2931

3032
## Settings
3133

tests/test_example.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
TOP = Path(__file__).absolute().parent.parent
1111

1212

13-
def copy_project(project_path: Path, trust: bool = False, **kwargs):
13+
def copy_project(project_path: Path, **kwargs):
1414
with open(TOP / "example-answers.yml") as f:
1515
answers = yaml.safe_load(f)
1616
answers.update(kwargs)
@@ -20,7 +20,6 @@ def copy_project(project_path: Path, trust: bool = False, **kwargs):
2020
dst_path=project_path,
2121
data=answers,
2222
vcs_ref="HEAD",
23-
unsafe=trust,
2423
)
2524
run_pipe("git add .", cwd=str(project_path))
2625

@@ -160,7 +159,7 @@ def test_example_repo_updates(tmp_path: Path):
160159
"https://github.com/DiamondLightSource/python-copier-template-example.git"
161160
)
162161
example_path = tmp_path / "example"
163-
copy_project(generated_path, trust=True)
162+
copy_project(generated_path)
164163
run_pipe(f"git clone {example_url} {example_path}")
165164
with open(example_path / ".copier-answers.yml") as f:
166165
d = yaml.safe_load(f)
@@ -171,7 +170,7 @@ def test_example_repo_updates(tmp_path: Path):
171170
run("git config user.email '[email protected]'")
172171
run("git config user.name 'Your Name'")
173172
run("git commit -am 'Update src'")
174-
run(f"copier update --trust --vcs-ref=HEAD --data-file {TOP}/example-answers.yml")
173+
run(f"copier update --vcs-ref=HEAD --data-file {TOP}/example-answers.yml")
175174
output = run(
176175
# Git directory expected to be different
177176
"diff -ur --exclude=.git "

0 commit comments

Comments
 (0)