Skip to content

Commit a0691f4

Browse files
authored
Merge pull request #9 from Facets-cloud/version-support-ftf
add versioning support for ftf cli
2 parents ef21d01 + ae30c16 commit a0691f4

2 files changed

Lines changed: 13 additions & 1 deletion

File tree

module-preview-action/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ jobs:
2222
control_plane_url: ${{ secrets.CONTROL_PLANE_URL }}
2323
username: ${{ secrets.FACETS_USERNAME }}
2424
token: ${{ secrets.FACETS_API_TOKEN }}
25+
ftf_cli_version: 0.2.1 # Optional: Specify only if you want to use a specific version of the CLI
2526
```
2627
2728
---
@@ -50,6 +51,7 @@ jobs:
5051
control_plane_url: ${{ secrets.CONTROL_PLANE_URL }}
5152
username: ${{ secrets.FACETS_USERNAME }}
5253
token: ${{ secrets.FACETS_API_TOKEN }}
54+
ftf_cli_version: 0.2.1 # Optional: Specify only if you want to use a specific version of the CLI
5355
```
5456
5557
## 🌱 Enabling Dry Run Mode

module-preview-action/action.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,10 @@ inputs:
3636
description: "Whether the modules registered in preview mode are publishable or not. This is not required if publish is set to true."
3737
required: false
3838
default: "false"
39+
ftf_cli_version:
40+
description: "Facets CLI version to use"
41+
required: false
42+
default: ""
3943

4044
runs:
4145
using: "composite"
@@ -62,7 +66,13 @@ runs:
6266
sudo apt-get install -y python3 python3-pip curl unzip jq git
6367
curl -fsSL https://releases.hashicorp.com/terraform/1.5.7/terraform_1.5.7_linux_amd64.zip -o terraform.zip
6468
unzip terraform.zip && mv terraform /usr/local/bin/ && rm terraform.zip
65-
pip install git+https://github.com/Facets-cloud/module-development-cli.git
69+
if [ -z "${{ inputs.ftf_cli_version }}" ]; then
70+
echo "🔍 Installing latest version of ftf-cli..."
71+
pip install ftf-cli
72+
else
73+
echo "🔍 Installing ftf-cli version ${{ inputs.ftf_cli_version }}..."
74+
pip install ftf-cli==${{ inputs.ftf_cli_version }}
75+
fi
6676
6777
- name: Identify All Facets Modules (All Modules)
6878
if: inputs.all-modules == 'true'

0 commit comments

Comments
 (0)