Added AI Generate Azure DevOps Task.
This commit is contained in:
17
scripts/build.sh
Executable file
17
scripts/build.sh
Executable file
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
||||
TASK_DIR="$ROOT_DIR/task/AzureFederatedAuth"
|
||||
BUILD_DIR="$ROOT_DIR/build"
|
||||
|
||||
cd "$TASK_DIR"
|
||||
rm -rf dist node_modules
|
||||
npm ci
|
||||
npm run build
|
||||
|
||||
cd "$ROOT_DIR"
|
||||
mkdir -p "$BUILD_DIR"
|
||||
npx tfx-cli extension create \
|
||||
--manifest-globs vss-extension.json \
|
||||
--output-path "$BUILD_DIR"
|
||||
26
scripts/publish.sh
Executable file
26
scripts/publish.sh
Executable file
@@ -0,0 +1,26 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
if [[ $# -lt 3 ]]; then
|
||||
echo "Usage: $0 <vsix-path> <publisher-id> <org1> [org2] [org3] ..."
|
||||
echo "Requires environment variable AZDO_PAT to be set."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z "${AZDO_PAT:-}" ]]; then
|
||||
echo "AZDO_PAT is not set."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
VSIX_PATH="$1"
|
||||
PUBLISHER_ID="$2"
|
||||
shift 2
|
||||
|
||||
for ORG in "$@"; do
|
||||
echo "Publishing to organization: $ORG"
|
||||
npx tfx-cli extension publish \
|
||||
--vsix "$VSIX_PATH" \
|
||||
--publisher "$PUBLISHER_ID" \
|
||||
--token "$AZDO_PAT" \
|
||||
--share-with "$ORG"
|
||||
done
|
||||
Reference in New Issue
Block a user