Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/dev' into v2
Browse files Browse the repository at this point in the history
  • Loading branch information
EyalDelarea committed Sep 13, 2023
2 parents d87d530 + b10022d commit 2821ca8
Show file tree
Hide file tree
Showing 18 changed files with 114 additions and 73 deletions.
23 changes: 23 additions & 0 deletions .github/RELEASE_LINK_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<details>
<summary>Downloads JFrog CLI</summary>

### Linux

[386](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-linux-386/jf)
[AMD-64](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-linux-amd64/jf)
[ARM-32](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-linux-arm/jf)
[ARM-64](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-linux-arm64/jf)
[PPC-64](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-linux-ppc64/jf)
[PPC-64-LE](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-linux-ppc64le/jf)
[S390X](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-linux-s390x/jf)

### MacOS

[AMD-64](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-mac-386/jf)
[ARM-64](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-mac-arm64/jf)

### Windows

[ARM-64](https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/{version}/jfrog-cli-windows-amd64/jf.exe)

</details>
27 changes: 27 additions & 0 deletions .github/workflows/addReleaseLinks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Add links on release
on:
release:
types: [created]

jobs:
add-links-on-release:
name: Add links on release
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v2

- name: Create markdown download links
run: |
# Remove the prefix 'v' from version.
RELEASE_VERSION=$(echo "${{ github.event.release.tag_name }}" | sed 's/^v//')
# Replace the place-holders '{version}' with the actual release version.
sed "s/{version}/$RELEASE_VERSION/g" ./.github/releaseLinkTemplate.md > ./temp_releaseLinkTemplate.md
- name: Add links to release notes
uses: softprops/action-gh-release@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
body_path: "temp_releaseLinkTemplate.md"
append_body: true
4 changes: 2 additions & 2 deletions access_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func TestRefreshableAccessTokens(t *testing.T) {
assert.NotEmpty(t, curRefreshToken)

// Make the token always refresh.
auth.InviteRefreshBeforeExpiryMinutes = 365 * 24 * 60
auth.RefreshPlatformTokenBeforeExpiryMinutes = 365 * 24 * 60

// Upload a file and assert tokens were refreshed.
uploadedFiles++
Expand All @@ -90,7 +90,7 @@ func TestRefreshableAccessTokens(t *testing.T) {
}

// Make the token not refresh. Verify Tokens did not refresh.
auth.InviteRefreshBeforeExpiryMinutes = 0
auth.RefreshPlatformTokenBeforeExpiryMinutes = 0
uploadedFiles++
err = uploadWithSpecificServerAndVerify(t, artifactoryCommandExecutor, "testdata/a/b/b2.in", uploadedFiles)
if !assert.NoError(t, err) {
Expand Down
4 changes: 2 additions & 2 deletions artifactory_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5268,7 +5268,7 @@ func TestRefreshableArtifactoryTokens(t *testing.T) {
assert.NotEmpty(t, curRefreshToken)

// Make the token always refresh.
auth.RefreshBeforeExpiryMinutes = 60
auth.RefreshArtifactoryTokenBeforeExpiryMinutes = 60

// Upload a file and assert tokens were refreshed.
uploadedFiles++
Expand Down Expand Up @@ -5312,7 +5312,7 @@ func TestRefreshableArtifactoryTokens(t *testing.T) {
}

// Make the token not refresh. Verify Tokens did not refresh.
auth.RefreshBeforeExpiryMinutes = 0
auth.RefreshArtifactoryTokenBeforeExpiryMinutes = 0
uploadedFiles++
err = uploadWithSpecificServerAndVerify(t, artifactoryCommandExecutor, "testdata/a/b/b2.in", uploadedFiles)
if err != nil {
Expand Down
7 changes: 3 additions & 4 deletions build/getcli/jf.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#!/bin/bash

CLI_OS="na"
CLI_UNAME="na"
CLI_MAJOR_VER="v2-jf"
VERSION="[RELEASE]"

Expand All @@ -13,11 +12,11 @@ else
echo "Downloading the latest version of JFrog CLI..."
fi

if $(echo "${OSTYPE}" | grep -q msys); then
if echo "${OSTYPE}" | grep -q msys; then
CLI_OS="windows"
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-windows-amd64/jf.exe"
FILE_NAME="jf.exe"
elif $(echo "${OSTYPE}" | grep -q darwin); then
elif echo "${OSTYPE}" | grep -q darwin; then
CLI_OS="mac"
if [[ $(uname -m) == 'arm64' ]]; then
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-mac-arm64/jf"
Expand Down Expand Up @@ -52,7 +51,7 @@ else
;;
*)
echo "Unknown machine type: $MACHINE_TYPE"
exit -1
exit 1
;;
esac
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-${CLI_OS}-${ARCH}/jf"
Expand Down
7 changes: 3 additions & 4 deletions build/getcli/jfrog.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#!/bin/bash

CLI_OS="na"
CLI_UNAME="na"
CLI_MAJOR_VER="v2"
VERSION="[RELEASE]"

Expand All @@ -13,11 +12,11 @@ else
echo "Downloading the latest version of JFrog CLI..."
fi

if $(echo "${OSTYPE}" | grep -q msys); then
if echo "${OSTYPE}" | grep -q msys; then
CLI_OS="windows"
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-windows-amd64/jfrog.exe"
FILE_NAME="jfrog.exe"
elif $(echo "${OSTYPE}" | grep -q darwin); then
elif echo "${OSTYPE}" | grep -q darwin; then
CLI_OS="mac"
if [[ $(uname -m) == 'arm64' ]]; then
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-mac-arm64/jfrog"
Expand Down Expand Up @@ -52,7 +51,7 @@ else
;;
*)
echo "Unknown machine type: $MACHINE_TYPE"
exit -1
exit 1
;;
esac
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-${CLI_OS}-${ARCH}/jfrog"
Expand Down
7 changes: 3 additions & 4 deletions build/installcli/jf.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#!/bin/bash

CLI_OS="na"
CLI_UNAME="na"
CLI_MAJOR_VER="v2-jf"
VERSION="[RELEASE]"
# Order is by destination priority.
Expand All @@ -16,11 +15,11 @@ else
fi
echo ""

if $(echo "${OSTYPE}" | grep -q msys); then
if echo "${OSTYPE}" | grep -q msys; then
CLI_OS="windows"
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-windows-amd64/jf.exe"
FILE_NAME="jf.exe"
elif $(echo "${OSTYPE}" | grep -q darwin); then
elif echo "${OSTYPE}" | grep -q darwin; then
CLI_OS="mac"
if [[ $(uname -m) == 'arm64' ]]; then
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-mac-arm64/jf"
Expand Down Expand Up @@ -55,7 +54,7 @@ else
;;
*)
echo "Unknown machine type: $MACHINE_TYPE"
exit -1
exit 1
;;
esac
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-${CLI_OS}-${ARCH}/jf"
Expand Down
7 changes: 3 additions & 4 deletions build/installcli/jfrog.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#!/bin/bash

CLI_OS="na"
CLI_UNAME="na"
CLI_MAJOR_VER="v2"
VERSION="[RELEASE]"
# Order is by destination priority.
Expand All @@ -16,11 +15,11 @@ else
fi
echo ""

if $(echo "${OSTYPE}" | grep -q msys); then
if echo "${OSTYPE}" | grep -q msys; then
CLI_OS="windows"
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-windows-amd64/jfrog.exe"
FILE_NAME="jfrog.exe"
elif $(echo "${OSTYPE}" | grep -q darwin); then
elif echo "${OSTYPE}" | grep -q darwin; then
CLI_OS="mac"
if [[ $(uname -m) == 'arm64' ]]; then
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-mac-arm64/jfrog"
Expand Down Expand Up @@ -55,7 +54,7 @@ else
;;
*)
echo "Unknown machine type: $MACHINE_TYPE"
exit -1
exit 1
;;
esac
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-${CLI_OS}-${ARCH}/jfrog"
Expand Down
2 changes: 1 addition & 1 deletion build/npm/v2-jf/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build/npm/v2-jf/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jfrog-cli-v2-jf",
"version": "2.46.3",
"version": "2.47.0",
"description": "🐸 Command-line interface for JFrog Artifactory, Xray, Distribution, Pipelines and Mission Control 🐸",
"homepage": "https://github.com/jfrog/jfrog-cli",
"preferGlobal": true,
Expand Down
2 changes: 1 addition & 1 deletion build/npm/v2/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build/npm/v2/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jfrog-cli-v2",
"version": "2.46.3",
"version": "2.47.0",
"description": "🐸 Command-line interface for JFrog Artifactory, Xray, Distribution, Pipelines and Mission Control 🐸",
"homepage": "https://github.com/jfrog/jfrog-cli",
"preferGlobal": true,
Expand Down
7 changes: 3 additions & 4 deletions build/setupcli/jf.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#!/bin/bash

CLI_OS="na"
CLI_UNAME="na"
CLI_MAJOR_VER="v2-jf"
VERSION="[RELEASE]"
# Order is by destination priority.
Expand All @@ -20,11 +19,11 @@ then
fi

echo "Downloading the latest version of JFrog CLI..."
if $(echo "${OSTYPE}" | grep -q msys); then
if echo "${OSTYPE}" | grep -q msys; then
CLI_OS="windows"
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-windows-amd64/jf.exe"
FILE_NAME="jf.exe"
elif $(echo "${OSTYPE}" | grep -q darwin); then
elif echo "${OSTYPE}" | grep -q darwin; then
CLI_OS="mac"
if [[ $(uname -m) == 'arm64' ]]; then
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-mac-arm64/jf"
Expand Down Expand Up @@ -59,7 +58,7 @@ else
;;
*)
echo "Unknown machine type: $MACHINE_TYPE"
exit -1
exit 1
;;
esac
URL="https://releases.jfrog.io/artifactory/jfrog-cli/${CLI_MAJOR_VER}/${VERSION}/jfrog-cli-${CLI_OS}-${ARCH}/jf"
Expand Down
19 changes: 5 additions & 14 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ go 1.20
require (
github.com/agnivade/levenshtein v1.1.1
github.com/buger/jsonparser v1.1.1
github.com/go-git/go-git/v5 v5.8.1
github.com/go-git/go-git/v5 v5.9.0
github.com/gocarina/gocsv v0.0.0-20230616125104-99d496ca653d
github.com/jfrog/build-info-go v1.9.10
github.com/jfrog/gofrog v1.3.0
github.com/jfrog/jfrog-cli-core/v2 v2.41.5
github.com/jfrog/jfrog-client-go v1.32.1
github.com/jfrog/jfrog-cli-core/v2 v2.43.0
github.com/jfrog/jfrog-client-go v1.32.2
github.com/jszwec/csvutil v1.8.0
github.com/mholt/archiver/v3 v3.5.1
github.com/stretchr/testify v1.8.4
Expand Down Expand Up @@ -42,6 +42,7 @@ require (
github.com/containerd/containerd v1.7.3 // indirect
github.com/cpuguy83/dockercfg v0.3.1 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect
github.com/cyphar/filepath-securejoin v0.2.4 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/docker/distribution v2.8.2+incompatible // indirect
github.com/docker/docker v24.0.5+incompatible // indirect
Expand All @@ -52,7 +53,7 @@ require (
github.com/forPelevin/gomoji v1.1.8 // indirect
github.com/fsnotify/fsnotify v1.6.0 // indirect
github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 // indirect
github.com/go-git/go-billy/v5 v5.4.1 // indirect
github.com/go-git/go-billy/v5 v5.5.0 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang-jwt/jwt/v4 v4.5.0 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
Expand Down Expand Up @@ -122,13 +123,3 @@ require (
gopkg.in/warnings.v0 v0.1.2 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

// replace github.com/jfrog/build-info-go => github.com/jfrog/build-info-go v1.8.9-0.20230828134416-f0db33dd9344

// replace github.com/jfrog/jfrog-cli-core/v2 => github.com/jfrog/jfrog-cli-core/v2 v2.31.1-0.20230907095444-fd00f19be95d

// replace github.com/jfrog/gofrog => github.com/jfrog/gofrog v1.2.6-0.20230418122323-2bf299dd6d27

// replace github.com/jfrog/jfrog-client-go => github.com/jfrog/jfrog-client-go v1.28.1-0.20230906115540-2c3c91d271d6

// replace github.com/jfrog/build-info-go => github.com/jfrog/build-info-go v1.8.9-0.20230905120411-62d1bdd4eb38
Loading

0 comments on commit 2821ca8

Please sign in to comment.