Skip to content

Commit b16ecea

Browse files
authored
chore: refining-env-file-generator (#32)
* chore: refining-env-file-generator * chore: temp setting algokit from feat branch 174489
1 parent f27e111 commit b16ecea

File tree

31 files changed

+141
-1
lines changed

31 files changed

+141
-1
lines changed

.github/workflows/check-python.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
run: pipx install poetry
1515

1616
- name: Install algokit
17-
run: pipx install algokit
17+
run: pipx install git+https://github.com/algorandfoundation/algokit-cli.git@chore/patching-tests
1818

1919
- name: Run algokit localnet
2020
run: algokit localnet start

examples/generators/production_python_smart_contract_python/.algokit/generators/create_env_file/copier.yaml

+28
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,32 @@ custom_network_name:
2424
placeholder: "custom"
2525
when: "{{ not use_generic_env and target_network == 'custom' }}"
2626

27+
is_localnet:
28+
type: bool
29+
help: Whether to deploy on localnet.
30+
placeholder: "true"
31+
default: "{{ target_network == 'localnet' and not use_generic_env }}"
32+
when: 'false'
33+
34+
is_testnet:
35+
type: bool
36+
help: Whether to deploy on testnet.
37+
placeholder: "true"
38+
default: "{{ target_network == 'testnet' and not use_generic_env }}"
39+
when: 'false'
40+
41+
is_mainnet:
42+
type: bool
43+
help: Whether to deploy on mainnet.
44+
placeholder: "true"
45+
default: "{{ target_network == 'mainnet' and not use_generic_env }}"
46+
when: 'false'
47+
48+
is_customnet:
49+
type: bool
50+
help: Whether to deploy on custom network.
51+
placeholder: "true"
52+
default: "{{ target_network == 'custom' and not use_generic_env }}"
53+
when: 'false'
54+
2755
_templates_suffix: ".j2"

examples/generators/production_python_smart_contract_typescript/.algokit/generators/create_env_file/copier.yaml

+28
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,32 @@ custom_network_name:
2424
placeholder: "custom"
2525
when: "{{ not use_generic_env and target_network == 'custom' }}"
2626

27+
is_localnet:
28+
type: bool
29+
help: Whether to deploy on localnet.
30+
placeholder: "true"
31+
default: "{{ target_network == 'localnet' and not use_generic_env }}"
32+
when: 'false'
33+
34+
is_testnet:
35+
type: bool
36+
help: Whether to deploy on testnet.
37+
placeholder: "true"
38+
default: "{{ target_network == 'testnet' and not use_generic_env }}"
39+
when: 'false'
40+
41+
is_mainnet:
42+
type: bool
43+
help: Whether to deploy on mainnet.
44+
placeholder: "true"
45+
default: "{{ target_network == 'mainnet' and not use_generic_env }}"
46+
when: 'false'
47+
48+
is_customnet:
49+
type: bool
50+
help: Whether to deploy on custom network.
51+
placeholder: "true"
52+
default: "{{ target_network == 'custom' and not use_generic_env }}"
53+
when: 'false'
54+
2755
_templates_suffix: ".j2"

examples/generators/starter_python_smart_contract_python/.algokit/generators/create_env_file/copier.yaml

+28
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,32 @@ custom_network_name:
2424
placeholder: "custom"
2525
when: "{{ not use_generic_env and target_network == 'custom' }}"
2626

27+
is_localnet:
28+
type: bool
29+
help: Whether to deploy on localnet.
30+
placeholder: "true"
31+
default: "{{ target_network == 'localnet' and not use_generic_env }}"
32+
when: 'false'
33+
34+
is_testnet:
35+
type: bool
36+
help: Whether to deploy on testnet.
37+
placeholder: "true"
38+
default: "{{ target_network == 'testnet' and not use_generic_env }}"
39+
when: 'false'
40+
41+
is_mainnet:
42+
type: bool
43+
help: Whether to deploy on mainnet.
44+
placeholder: "true"
45+
default: "{{ target_network == 'mainnet' and not use_generic_env }}"
46+
when: 'false'
47+
48+
is_customnet:
49+
type: bool
50+
help: Whether to deploy on custom network.
51+
placeholder: "true"
52+
default: "{{ target_network == 'custom' and not use_generic_env }}"
53+
when: 'false'
54+
2755
_templates_suffix: ".j2"

examples/generators/starter_python_smart_contract_typescript/.algokit/generators/create_env_file/copier.yaml

+28
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,32 @@ custom_network_name:
2424
placeholder: "custom"
2525
when: "{{ not use_generic_env and target_network == 'custom' }}"
2626

27+
is_localnet:
28+
type: bool
29+
help: Whether to deploy on localnet.
30+
placeholder: "true"
31+
default: "{{ target_network == 'localnet' and not use_generic_env }}"
32+
when: 'false'
33+
34+
is_testnet:
35+
type: bool
36+
help: Whether to deploy on testnet.
37+
placeholder: "true"
38+
default: "{{ target_network == 'testnet' and not use_generic_env }}"
39+
when: 'false'
40+
41+
is_mainnet:
42+
type: bool
43+
help: Whether to deploy on mainnet.
44+
placeholder: "true"
45+
default: "{{ target_network == 'mainnet' and not use_generic_env }}"
46+
when: 'false'
47+
48+
is_customnet:
49+
type: bool
50+
help: Whether to deploy on custom network.
51+
placeholder: "true"
52+
default: "{{ target_network == 'custom' and not use_generic_env }}"
53+
when: 'false'
54+
2755
_templates_suffix: ".j2"

template_content/.algokit/generators/create_env_file/copier.yaml

+28
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,32 @@ custom_network_name:
2424
placeholder: "custom"
2525
when: "{{ not use_generic_env and target_network == 'custom' }}"
2626

27+
is_localnet:
28+
type: bool
29+
help: Whether to deploy on localnet.
30+
placeholder: "true"
31+
default: "{{ target_network == 'localnet' and not use_generic_env }}"
32+
when: 'false'
33+
34+
is_testnet:
35+
type: bool
36+
help: Whether to deploy on testnet.
37+
placeholder: "true"
38+
default: "{{ target_network == 'testnet' and not use_generic_env }}"
39+
when: 'false'
40+
41+
is_mainnet:
42+
type: bool
43+
help: Whether to deploy on mainnet.
44+
placeholder: "true"
45+
default: "{{ target_network == 'mainnet' and not use_generic_env }}"
46+
when: 'false'
47+
48+
is_customnet:
49+
type: bool
50+
help: Whether to deploy on custom network.
51+
placeholder: "true"
52+
default: "{{ target_network == 'custom' and not use_generic_env }}"
53+
when: 'false'
54+
2755
_templates_suffix: ".j2"

0 commit comments

Comments
 (0)