mirror of
https://github.com/Stone-Red-Code/docs-desktop.git
synced 2026-09-07 23:43:19 +02:00
Merge pull request #1114 from dotnet/publish-3176
This commit is contained in:
@@ -18,13 +18,14 @@ on:
|
|||||||
- "**.vbproj"
|
- "**.vbproj"
|
||||||
- "**.fsproj"
|
- "**.fsproj"
|
||||||
- "**.vcxproj"
|
- "**.vcxproj"
|
||||||
|
- "**.sln"
|
||||||
- "**global.json"
|
- "**global.json"
|
||||||
- "**snippets.5000.json"
|
- "**snippets.5000.json"
|
||||||
branches: '*'
|
branches: '*'
|
||||||
|
|
||||||
env:
|
env:
|
||||||
DOTNET_INSTALLER_CHANNEL: 'release/5.0.1xx'
|
DOTNET_INSTALLER_CHANNEL: '6.0'
|
||||||
DOTNET_DO_INSTALL: 'false'
|
DOTNET_DO_INSTALL: 'true'
|
||||||
EnableNuGetPackageRestore: 'True'
|
EnableNuGetPackageRestore: 'True'
|
||||||
|
|
||||||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||||
@@ -40,14 +41,19 @@ jobs:
|
|||||||
- uses: actions/checkout@a81bbbf8298c0fa03ea29cdc473d45769f953675 #@v2
|
- uses: actions/checkout@a81bbbf8298c0fa03ea29cdc473d45769f953675 #@v2
|
||||||
|
|
||||||
# Get the latest preview SDK (or sdk not installed by the runner)
|
# Get the latest preview SDK (or sdk not installed by the runner)
|
||||||
- name: Setup .NET Core SDK Preview
|
- name: Setup .NET SDK
|
||||||
if: ${{ env.DOTNET_DO_INSTALL == 'true' }}
|
if: ${{ env.DOTNET_DO_INSTALL == 'true' }}
|
||||||
run: |
|
run: |
|
||||||
echo "Downloading dotnet-install.ps1"
|
echo "Downloading dotnet-install.ps1"
|
||||||
Invoke-WebRequest https://raw.githubusercontent.com/dotnet/install-scripts/master/src/dotnet-install.ps1 -OutFile dotnet-install.ps1
|
Invoke-WebRequest https://raw.githubusercontent.com/dotnet/install-scripts/master/src/dotnet-install.ps1 -OutFile dotnet-install.ps1
|
||||||
echo "Installing dotnet version ${{ env.DOTNET_INSTALLER_CHANNEL }}"
|
echo "Installing dotnet version ${{ env.DOTNET_INSTALLER_CHANNEL }}"
|
||||||
.\dotnet-install.ps1 -InstallDir "c:\program files\dotnet" -Channel "${{ env.DOTNET_INSTALLER_CHANNEL }}"
|
.\dotnet-install.ps1 -InstallDir "c:\program files\dotnet" -Channel "${{ env.DOTNET_INSTALLER_CHANNEL }}"
|
||||||
|
|
||||||
|
# Print dotnet info
|
||||||
|
- name: Display .NET info
|
||||||
|
run: |
|
||||||
|
dotnet --info
|
||||||
|
|
||||||
# Install locate projs global tool
|
# Install locate projs global tool
|
||||||
- name: Install LocateProjects tool
|
- name: Install LocateProjects tool
|
||||||
run: |
|
run: |
|
||||||
@@ -72,6 +78,3 @@ jobs:
|
|||||||
- name: Report status
|
- name: Report status
|
||||||
run: |
|
run: |
|
||||||
./.github/workflows/dependencies/Out-GithubActionStatus.ps1
|
./.github/workflows/dependencies/Out-GithubActionStatus.ps1
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,19 @@
|
|||||||
|
on: [pull_request_target]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
comment:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/github-script@v4
|
||||||
|
env:
|
||||||
|
SHOULD_COMMENT: ${{ github.base_ref == 'refs/heads/live' && !(github.event.issue.user.login == 'cxwtool' || github.head_ref == 'refs/heads/main') }}
|
||||||
|
with:
|
||||||
|
script: |
|
||||||
|
if (process.env.SHOULD_COMMENT == 'true') {
|
||||||
|
github.issues.createComment({
|
||||||
|
issue_number: context.issue.number,
|
||||||
|
owner: context.repo.owner,
|
||||||
|
repo: context.repo.repo,
|
||||||
|
body: 'It looks like this pull request may have been opened on the `live` branch by mistake. In general, PRs should target the `main` branch.'
|
||||||
|
})
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user