Skip to content

Commit

Permalink
Add permissions and setup environment variables for build workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Ahmed Magdy <amagdy@microsoft.com>
  • Loading branch information
amgdy committed Mar 19, 2024
1 parent 117d638 commit 6a3c9d3
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ on:
type: boolean
default: false

permissions:
contents: read
security-events: write

env:
VERSION: ${{ github.event.inputs.Version }}
SELF_CONTAINED: ${{ github.event.inputs.SelfContained }}
Expand All @@ -22,18 +26,26 @@ jobs:
runs-on: windows-2022
env:
APP_PROJECT_PATH: src/Magdys.ScreenPrivacyWatermark.App/Magdys.ScreenPrivacyWatermark.App.csproj
APP_PROJECT_OUTPUT: ${RUNNER_TEMP}/app
APP_PROJECT_OUTPUT: temp/app
MSI_PROJECT_PATH: src/Magdys.ScreenPrivacyWatermark.Setup/Magdys.ScreenPrivacyWatermark.Setup.wixproj
MSI_PROJECT_OUTPUT: ${RUNNER_TEMP}/msi
MSI_PROJECT_OUTPUT: temp/msi
MSI_FILE_NAME: SPW-${{github.event.inputs.Version}}-Setup

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup envs
run: |
echo "APP_PROJECT_OUTPUT=${{ runner.temp }}/app" >> $GITHUB_ENV
echo "MSI_PROJECT_OUTPUT=${{ runner.temp }}/msi" >> $GITHUB_ENV
- name: List All env
run: Get-ChildItem env:* | Sort-Object -Property Name

- name: Dependency Review
uses: actions/dependency-review-action@v4

- name: Setup .NET 8
if: false
uses: actions/setup-dotnet@v4
Expand Down

0 comments on commit 6a3c9d3

Please sign in to comment.