diff --git a/template_content/.gitignore.jinja b/template_content/.gitignore.jinja index 4a926bb..e5f0b9e 100644 --- a/template_content/.gitignore.jinja +++ b/template_content/.gitignore.jinja @@ -176,3 +176,5 @@ node_modules # AlgoKit debug_traces/ + +.algokit/static-analysis/tealer/ diff --git a/template_content/{% if ide_vscode %}.vscode{% endif %}/tasks.json b/template_content/{% if ide_vscode %}.vscode{% endif %}/tasks.json index 4873ec8..b7c72d0 100644 --- a/template_content/{% if ide_vscode %}.vscode{% endif %}/tasks.json +++ b/template_content/{% if ide_vscode %}.vscode{% endif %}/tasks.json @@ -59,6 +59,21 @@ "cwd": "${workspaceFolder}" }, "problemMatcher": [] + }, + { + "label": "Analyze TEAL contracts with AlgoKit Tealer integration", + "command": "algokit", + "args": [ + "task", + "analyze", + "${workspaceFolder}/.algokit", + "--recursive", + "--force" + ], + "options": { + "cwd": "${workspaceFolder}" + }, + "problemMatcher": [] } ] } diff --git a/template_content/{% if use_github_actions %}.github{% endif %}/workflows/checks.yaml.jinja b/template_content/{% if use_github_actions %}.github{% endif %}/workflows/checks.yaml.jinja index a4b39c0..62f023a 100644 --- a/template_content/{% if use_github_actions %}.github{% endif %}/workflows/checks.yaml.jinja +++ b/template_content/{% if use_github_actions %}.github{% endif %}/workflows/checks.yaml.jinja @@ -83,6 +83,9 @@ jobs: - name: Build smart contracts run: poetry run python -m smart_contracts build + - name: Scan TEAL files for issues + run: algokit task analyze .algokit --recursive --force # add --diff flag if you want output stability checks instead + - name: Check output stability of the smart contracts shell: bash run: | diff --git a/template_content/{% if use_pre_commit %}.pre-commit-config.yaml{% endif %}.jinja b/template_content/{% if use_pre_commit %}.pre-commit-config.yaml{% endif %}.jinja index c2f10a9..eb7a8a7 100644 --- a/template_content/{% if use_pre_commit %}.pre-commit-config.yaml{% endif %}.jinja +++ b/template_content/{% if use_pre_commit %}.pre-commit-config.yaml{% endif %}.jinja @@ -36,3 +36,13 @@ repos: minimum_pre_commit_version: '2.9.2' files: '^(src|tests)/' {% endif %} + - id: tealer + name: tealer + description: "Run AlgoKit `Tealer` for TEAL static analysis" + entry: algokit + language: system + args: [task, analyze, ".algokit", "--recursive", "--force"] + require_serial: false + additional_dependencies: [] + minimum_pre_commit_version: "0" + files: '^.*\.teal$' diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_python/.github/workflows/checks.yaml b/tests_generated/test_smart_contract_generator_default_production_preset_python/.github/workflows/checks.yaml index f6d0102..d5550b5 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_python/.github/workflows/checks.yaml +++ b/tests_generated/test_smart_contract_generator_default_production_preset_python/.github/workflows/checks.yaml @@ -67,6 +67,9 @@ jobs: - name: Build smart contracts run: poetry run python -m smart_contracts build + - name: Scan TEAL files for issues + run: algokit task analyze .algokit --recursive --force # add --diff flag if you want output stability checks instead + - name: Check output stability of the smart contracts shell: bash run: | diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_python/.gitignore b/tests_generated/test_smart_contract_generator_default_production_preset_python/.gitignore index 4a926bb..e5f0b9e 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_python/.gitignore +++ b/tests_generated/test_smart_contract_generator_default_production_preset_python/.gitignore @@ -176,3 +176,5 @@ node_modules # AlgoKit debug_traces/ + +.algokit/static-analysis/tealer/ diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_python/.pre-commit-config.yaml b/tests_generated/test_smart_contract_generator_default_production_preset_python/.pre-commit-config.yaml index 93bfff5..8862f86 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_python/.pre-commit-config.yaml +++ b/tests_generated/test_smart_contract_generator_default_production_preset_python/.pre-commit-config.yaml @@ -36,3 +36,13 @@ repos: minimum_pre_commit_version: '2.9.2' files: '^(src|tests)/' + - id: tealer + name: tealer + description: "Run AlgoKit `Tealer` for TEAL static analysis" + entry: algokit + language: system + args: [task, analyze, ".algokit", "--recursive", "--force"] + require_serial: false + additional_dependencies: [] + minimum_pre_commit_version: "0" + files: '^.*\.teal$' diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_python/.vscode/tasks.json b/tests_generated/test_smart_contract_generator_default_production_preset_python/.vscode/tasks.json index 4873ec8..b7c72d0 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_python/.vscode/tasks.json +++ b/tests_generated/test_smart_contract_generator_default_production_preset_python/.vscode/tasks.json @@ -59,6 +59,21 @@ "cwd": "${workspaceFolder}" }, "problemMatcher": [] + }, + { + "label": "Analyze TEAL contracts with AlgoKit Tealer integration", + "command": "algokit", + "args": [ + "task", + "analyze", + "${workspaceFolder}/.algokit", + "--recursive", + "--force" + ], + "options": { + "cwd": "${workspaceFolder}" + }, + "problemMatcher": [] } ] } diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.github/workflows/checks.yaml b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.github/workflows/checks.yaml index 0f20db5..bfaed08 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.github/workflows/checks.yaml +++ b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.github/workflows/checks.yaml @@ -61,6 +61,9 @@ jobs: - name: Build smart contracts run: poetry run python -m smart_contracts build + - name: Scan TEAL files for issues + run: algokit task analyze .algokit --recursive --force # add --diff flag if you want output stability checks instead + - name: Check output stability of the smart contracts shell: bash run: | diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.gitignore b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.gitignore index 4a926bb..e5f0b9e 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.gitignore +++ b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.gitignore @@ -176,3 +176,5 @@ node_modules # AlgoKit debug_traces/ + +.algokit/static-analysis/tealer/ diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.pre-commit-config.yaml b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.pre-commit-config.yaml index 93bfff5..8862f86 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.pre-commit-config.yaml +++ b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.pre-commit-config.yaml @@ -36,3 +36,13 @@ repos: minimum_pre_commit_version: '2.9.2' files: '^(src|tests)/' + - id: tealer + name: tealer + description: "Run AlgoKit `Tealer` for TEAL static analysis" + entry: algokit + language: system + args: [task, analyze, ".algokit", "--recursive", "--force"] + require_serial: false + additional_dependencies: [] + minimum_pre_commit_version: "0" + files: '^.*\.teal$' diff --git a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.vscode/tasks.json b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.vscode/tasks.json index 4873ec8..b7c72d0 100644 --- a/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.vscode/tasks.json +++ b/tests_generated/test_smart_contract_generator_default_production_preset_typescript/.vscode/tasks.json @@ -59,6 +59,21 @@ "cwd": "${workspaceFolder}" }, "problemMatcher": [] + }, + { + "label": "Analyze TEAL contracts with AlgoKit Tealer integration", + "command": "algokit", + "args": [ + "task", + "analyze", + "${workspaceFolder}/.algokit", + "--recursive", + "--force" + ], + "options": { + "cwd": "${workspaceFolder}" + }, + "problemMatcher": [] } ] } diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.github/workflows/checks.yaml b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.github/workflows/checks.yaml index f6d0102..d5550b5 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.github/workflows/checks.yaml +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.github/workflows/checks.yaml @@ -67,6 +67,9 @@ jobs: - name: Build smart contracts run: poetry run python -m smart_contracts build + - name: Scan TEAL files for issues + run: algokit task analyze .algokit --recursive --force # add --diff flag if you want output stability checks instead + - name: Check output stability of the smart contracts shell: bash run: | diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.gitignore b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.gitignore index 4a926bb..e5f0b9e 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.gitignore +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.gitignore @@ -176,3 +176,5 @@ node_modules # AlgoKit debug_traces/ + +.algokit/static-analysis/tealer/ diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.pre-commit-config.yaml b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.pre-commit-config.yaml index 93bfff5..8862f86 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.pre-commit-config.yaml +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.pre-commit-config.yaml @@ -36,3 +36,13 @@ repos: minimum_pre_commit_version: '2.9.2' files: '^(src|tests)/' + - id: tealer + name: tealer + description: "Run AlgoKit `Tealer` for TEAL static analysis" + entry: algokit + language: system + args: [task, analyze, ".algokit", "--recursive", "--force"] + require_serial: false + additional_dependencies: [] + minimum_pre_commit_version: "0" + files: '^.*\.teal$' diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.vscode/tasks.json b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.vscode/tasks.json index 4873ec8..b7c72d0 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_python/.vscode/tasks.json +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_python/.vscode/tasks.json @@ -59,6 +59,21 @@ "cwd": "${workspaceFolder}" }, "problemMatcher": [] + }, + { + "label": "Analyze TEAL contracts with AlgoKit Tealer integration", + "command": "algokit", + "args": [ + "task", + "analyze", + "${workspaceFolder}/.algokit", + "--recursive", + "--force" + ], + "options": { + "cwd": "${workspaceFolder}" + }, + "problemMatcher": [] } ] } diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.github/workflows/checks.yaml b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.github/workflows/checks.yaml index 0f20db5..bfaed08 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.github/workflows/checks.yaml +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.github/workflows/checks.yaml @@ -61,6 +61,9 @@ jobs: - name: Build smart contracts run: poetry run python -m smart_contracts build + - name: Scan TEAL files for issues + run: algokit task analyze .algokit --recursive --force # add --diff flag if you want output stability checks instead + - name: Check output stability of the smart contracts shell: bash run: | diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.gitignore b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.gitignore index 4a926bb..e5f0b9e 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.gitignore +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.gitignore @@ -176,3 +176,5 @@ node_modules # AlgoKit debug_traces/ + +.algokit/static-analysis/tealer/ diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.pre-commit-config.yaml b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.pre-commit-config.yaml index 93bfff5..8862f86 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.pre-commit-config.yaml +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.pre-commit-config.yaml @@ -36,3 +36,13 @@ repos: minimum_pre_commit_version: '2.9.2' files: '^(src|tests)/' + - id: tealer + name: tealer + description: "Run AlgoKit `Tealer` for TEAL static analysis" + entry: algokit + language: system + args: [task, analyze, ".algokit", "--recursive", "--force"] + require_serial: false + additional_dependencies: [] + minimum_pre_commit_version: "0" + files: '^.*\.teal$' diff --git a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.vscode/tasks.json b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.vscode/tasks.json index 4873ec8..b7c72d0 100644 --- a/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.vscode/tasks.json +++ b/tests_generated/test_smart_contract_generator_default_starter_preset_typescript/.vscode/tasks.json @@ -59,6 +59,21 @@ "cwd": "${workspaceFolder}" }, "problemMatcher": [] + }, + { + "label": "Analyze TEAL contracts with AlgoKit Tealer integration", + "command": "algokit", + "args": [ + "task", + "analyze", + "${workspaceFolder}/.algokit", + "--recursive", + "--force" + ], + "options": { + "cwd": "${workspaceFolder}" + }, + "problemMatcher": [] } ] }