Skip to content

Commit 7d6c3cb

Browse files
committed
JGC-395 - Change repo layout and settings
1 parent d3e1554 commit 7d6c3cb

31 files changed

+455
-340
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
- [ ] All [tests](https://github.com/jfrog/jfrog-cli/CONTRIBUTING.md#tests) have passed. If this feature is not already covered by the tests, new tests have been added.
2-
- [ ] The pull request is targeting the `dev` branch.
2+
- [ ] The pull request is targeting the `master` branch.
33
- [ ] The code has been validated to compile successfully by running `go vet ./...`.
44
- [ ] The code has been formatted properly using `go fmt ./...`.
55

.github/dependabot.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "gomod"
4+
directory: "/"
5+
schedule:
6+
interval: "daily"
7+
open-pull-requests-limit: 10
8+
groups:
9+
go:
10+
update-types:
11+
- minor
12+
- patch

.github/workflows/accessTests.yml

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
name: Access Tests
22
on:
3+
workflow_dispatch:
34
push:
45
branches:
5-
- '**'
6-
tags-ignore:
7-
- '**'
8-
# Triggers the workflow on labeled PRs only.
9-
pull_request_target:
10-
types: [ labeled ]
6+
- "master"
7+
# Triggers the workflow on PRs to master branch only.
8+
pull_request:
9+
types: [opened, synchronize]
10+
branches:
11+
- "master"
12+
1113
# Ensures that only the latest commit is running for each PR at a time.
1214
concurrency:
1315
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.ref }}
@@ -17,12 +19,11 @@ permissions:
1719
contents: read
1820
jobs:
1921
Access-Tests:
20-
if: contains(github.event.pull_request.labels.*.name, 'safe to test') || github.event_name == 'push'
2122
name: Access tests (${{ matrix.os }})
2223
strategy:
2324
fail-fast: false
2425
matrix:
25-
os: [ ubuntu, windows, macos ]
26+
os: [ubuntu, windows, macos]
2627
runs-on: ${{ matrix.os }}-latest
2728
steps:
2829
- name: Checkout code
@@ -33,10 +34,25 @@ jobs:
3334
- name: Setup Go with cache
3435
uses: jfrog/.github/actions/install-go-with-cache@main
3536

37+
- name: Debug macOS Environment and Set Timeout
38+
if: runner.os == 'macOS'
39+
run: |
40+
echo "=== macOS Debug Information ==="
41+
echo "Architecture: $(uname -m)"
42+
echo "macOS Version: $(sw_vers -productVersion)"
43+
echo "macOS Build: $(sw_vers -buildVersion)"
44+
echo "Available memory: $(system_profiler SPHardwareDataType | grep Memory || echo 'Memory info not available')"
45+
echo "Available disk space: $(df -h)"
46+
echo "Java version: $(java -version 2>&1 || echo 'Java not found')"
47+
echo "Go version: $(go version)"
48+
echo "Setting RT_CONNECTION_TIMEOUT_SECONDS to 2400 for macOS"
49+
echo "RT_CONNECTION_TIMEOUT_SECONDS=2400" >> $GITHUB_ENV
50+
3651
- name: Install local Artifactory
3752
uses: jfrog/.github/actions/install-local-artifactory@main
3853
with:
3954
RTLIC: ${{ secrets.RTLIC }}
55+
RT_CONNECTION_TIMEOUT_SECONDS: ${{ env.RT_CONNECTION_TIMEOUT_SECONDS || '1200' }}
4056

4157
- name: Get ID Token and Exchange Token
4258
shell: bash

.github/workflows/analysis.yml

Lines changed: 28 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,20 @@
11
name: "Static Analysis"
22
on:
3+
workflow_dispatch:
34
push:
45
branches:
5-
- '**'
6-
tags-ignore:
7-
- '**'
6+
- "master"
87
pull_request:
8+
types: [opened, synchronize]
9+
branches:
10+
- "master"
911
concurrency:
1012
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.ref }}
1113
cancel-in-progress: true
1214
jobs:
1315
Go-Lint:
14-
name: Lint ${{ matrix.os }}
15-
strategy:
16-
fail-fast: false
17-
matrix:
18-
os: [ ubuntu, windows, macos ]
19-
runs-on: ${{ matrix.os }}-latest
16+
name: Lint
17+
runs-on: ubuntu-latest
2018
steps:
2119
- name: Checkout code
2220
uses: actions/checkout@v4
@@ -30,7 +28,7 @@ jobs:
3028
run: go vet -v ./...
3129

3230
Static-Check:
33-
name: Static Check ubuntu-latest
31+
name: Static Check
3432
runs-on: ubuntu-latest
3533
steps:
3634
- name: Checkout Source
@@ -41,17 +39,17 @@ jobs:
4139

4240
- name: Run golangci linter
4341
uses: jfrog/.github/actions/golangci-lint@main
44-
42+
4543
Go-Sec:
46-
name: Go-Sec ubuntu-latest
44+
name: Go-Sec
4745
runs-on: ubuntu-latest
4846
steps:
4947
- name: Checkout Source
5048
uses: actions/checkout@v4
5149

5250
- name: Setup Go with cache
5351
uses: jfrog/.github/actions/install-go-with-cache@main
54-
52+
5553
- name: Run Go-Sec scanner
5654
uses: jfrog/.github/actions/gosec-scanner@main
5755

@@ -65,4 +63,20 @@ jobs:
6563
- name: Run ShellCheck
6664
uses: ludeeus/action-shellcheck@master
6765
with:
68-
ignore_paths: '*test*'
66+
ignore_paths: "*test*"
67+
68+
No-Replace:
69+
runs-on: ubuntu-latest
70+
steps:
71+
- name: Checkout Source
72+
uses: actions/checkout@v4
73+
74+
- name: Check for uncommented replace instructions on JFrog dependencies
75+
run: |
76+
if grep -E '^[[:space:]]*replace[[:space:]]+github\.com/jfrog' go.mod; then
77+
echo "❌ Found uncommented replace directives for JFrog dependencies in go.mod"
78+
echo "All replace directives for JFrog dependencies should be commented out"
79+
exit 1
80+
else
81+
echo "✅ No uncommented replace directives for JFrog dependencies found in go.mod"
82+
fi

.github/workflows/artifactoryTests.yml

Lines changed: 25 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,27 @@
11
name: Artifactory Tests
22
on:
3+
workflow_dispatch:
34
push:
45
branches:
5-
- '**'
6-
tags-ignore:
7-
- '**'
8-
# Triggers the workflow on labeled PRs only.
9-
pull_request_target:
10-
types: [ labeled ]
6+
- "master"
7+
# Triggers the workflow on PRs to master branch only.
8+
pull_request:
9+
types: [opened, synchronize]
10+
branches:
11+
- "master"
12+
1113
# Ensures that only the latest commit is running for each PR at a time.
1214
concurrency:
1315
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.ref }}
1416
cancel-in-progress: true
1517
jobs:
1618
Artifactory-Tests:
17-
if: contains(github.event.pull_request.labels.*.name, 'safe to test') || github.event_name == 'push'
1819
name: ${{ matrix.suite }} ${{ matrix.os }}
1920
strategy:
2021
fail-fast: false
2122
matrix:
22-
suite: [ artifactory, artifactoryProject ]
23-
os: [ ubuntu, windows, macos ]
23+
suite: [artifactory, artifactoryProject]
24+
os: [ubuntu, windows, macos]
2425
runs-on: ${{ matrix.os }}-latest
2526
env:
2627
JFROG_CLI_LOG_LEVEL: DEBUG
@@ -33,10 +34,25 @@ jobs:
3334
- name: Setup Go with cache
3435
uses: jfrog/.github/actions/install-go-with-cache@main
3536

37+
- name: Debug macOS Environment and Set Timeout
38+
if: runner.os == 'macOS'
39+
run: |
40+
echo "=== macOS Debug Information ==="
41+
echo "Architecture: $(uname -m)"
42+
echo "macOS Version: $(sw_vers -productVersion)"
43+
echo "macOS Build: $(sw_vers -buildVersion)"
44+
echo "Available memory: $(system_profiler SPHardwareDataType | grep Memory || echo 'Memory info not available')"
45+
echo "Available disk space: $(df -h)"
46+
echo "Java version: $(java -version 2>&1 || echo 'Java not found')"
47+
echo "Go version: $(go version)"
48+
echo "Setting RT_CONNECTION_TIMEOUT_SECONDS to 2400 for macOS"
49+
echo "RT_CONNECTION_TIMEOUT_SECONDS=2400" >> $GITHUB_ENV
50+
3651
- name: Install local Artifactory
3752
uses: jfrog/.github/actions/install-local-artifactory@main
3853
with:
3954
RTLIC: ${{ secrets.RTLIC }}
55+
RT_CONNECTION_TIMEOUT_SECONDS: ${{ env.RT_CONNECTION_TIMEOUT_SECONDS || '1200' }}
4056

4157
- name: Run Artifactory tests
4258
run: go test -v github.com/jfrog/jfrog-cli --timeout 0 --test.artifactory --jfrog.url=http://127.0.0.1:8082 --jfrog.adminToken=${{ env.JFROG_TESTS_LOCAL_ACCESS_TOKEN }}

.github/workflows/distributionTests.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,26 @@
11
name: Distribution Tests
22
on:
3+
workflow_dispatch:
34
push:
45
branches:
5-
- '**'
6-
tags-ignore:
7-
- '**'
8-
# Triggers the workflow on labeled PRs only.
9-
pull_request_target:
10-
types: [labeled]
6+
- "master"
7+
# Triggers the workflow on PRs to master branch only.
8+
pull_request:
9+
types: [opened, synchronize]
10+
branches:
11+
- "master"
12+
1113
# Ensures that only the latest commit is running for each PR at a time.
1214
concurrency:
1315
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.ref }}
1416
cancel-in-progress: true
1517
jobs:
1618
Distribution-Tests:
17-
if: contains(github.event.pull_request.labels.*.name, 'safe to test') || github.event_name == 'push'
1819
name: Distribution tests (${{ matrix.os }})
1920
strategy:
2021
fail-fast: false
2122
matrix:
22-
os: [ ubuntu, windows, macos ]
23+
os: [ubuntu, windows, macos]
2324
runs-on: ${{ matrix.os }}-latest
2425
steps:
2526
- name: Setup Go with cache

.github/workflows/dockerTests.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
11
name: Docker Tests
22
on:
3+
workflow_dispatch:
34
push:
45
branches:
5-
- '**'
6-
tags-ignore:
7-
- '**'
8-
# Triggers the workflow on labeled PRs only.
9-
pull_request_target:
10-
types: [labeled]
6+
- "master"
7+
# Triggers the workflow on PRs to master branch only.
8+
pull_request:
9+
types: [opened, synchronize]
10+
branches:
11+
- "master"
12+
1113
# Ensures that only the latest commit is running for each PR at a time.
1214
concurrency:
1315
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.ref }}
1416
cancel-in-progress: true
1517
jobs:
1618
Docker-tests:
17-
if: contains(github.event.pull_request.labels.*.name, 'safe to test') || github.event_name == 'push'
1819
name: ubuntu-latest
1920
runs-on: ubuntu-latest
2021
steps:

.github/workflows/frogbot-scan-pull-request.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
name: "Frogbot Scan Pull Request"
22
on:
33
pull_request_target:
4-
types: [ opened, synchronize ]
4+
types: [opened, synchronize]
5+
branches:
6+
- "master"
57
permissions:
68
pull-requests: write
79
contents: read
@@ -121,4 +123,3 @@ jobs:
121123
# Set the minimum severity for vulnerabilities that should be fixed and commented on in pull requests
122124
# The following values are accepted: Low, Medium, High or Critical
123125
# JF_MIN_SEVERITY: ""
124-

.github/workflows/goTests.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,27 @@
11
name: Go Tests
22
on:
3+
workflow_dispatch:
34
push:
45
branches:
5-
- '**'
6-
tags-ignore:
7-
- '**'
8-
# Triggers the workflow on labeled PRs only.
9-
pull_request_target:
10-
types: [labeled]
6+
- "master"
7+
# Triggers the workflow on PRs to master branch only.
8+
pull_request:
9+
types: [opened, synchronize]
10+
branches:
11+
- "master"
12+
1113
# Ensures that only the latest commit is running for each PR at a time.
1214
concurrency:
1315
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.ref }}
1416
cancel-in-progress: true
1517
jobs:
1618
GO-tests:
1719
# Go modules doesn't allow passing credentials to a private registry using an HTTP URL. Therefore, the Go tests run against a remote Artifactory server.
18-
if: contains(github.event.pull_request.labels.*.name, 'safe to test') || github.event_name == 'push'
1920
name: Go tests (${{ matrix.os }})
2021
strategy:
2122
fail-fast: false
2223
matrix:
23-
os: [ ubuntu, windows, macos ]
24+
os: [ubuntu, windows, macos]
2425
runs-on: ${{ matrix.os }}-latest
2526
steps:
2627
- name: Checkout code

0 commit comments

Comments
 (0)