Skip to content

Commit

Permalink
Merge branch 'master' into filecollector-language
Browse files Browse the repository at this point in the history
  • Loading branch information
adangel committed Jul 29, 2022
2 parents 1b5f7e8 + bf5828d commit 2cfdc9c
Show file tree
Hide file tree
Showing 287 changed files with 11,398 additions and 1,985 deletions.
133 changes: 131 additions & 2 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -3267,7 +3267,8 @@
"avatar_url": "https://avatars.githubusercontent.com/u/24591067?v=4",
"profile": "https://github.com/jborgers",
"contributions": [
"bug"
"bug",
"code"
]
},
{
Expand Down Expand Up @@ -3384,7 +3385,8 @@
"avatar_url": "https://avatars.githubusercontent.com/u/242337?v=4",
"profile": "https://github.com/jjlharrison",
"contributions": [
"bug"
"bug",
"code"
]
},
{
Expand Down Expand Up @@ -6639,6 +6641,133 @@
"contributions": [
"code"
]
},
{
"login": "lukelukes",
"name": "lukelukes",
"avatar_url": "https://avatars.githubusercontent.com/u/45536418?v=4",
"profile": "https://github.com/lukelukes",
"contributions": [
"code"
]
},
{
"login": "vibhory2j",
"name": "Vibhor Goyal",
"avatar_url": "https://avatars.githubusercontent.com/u/15845016?v=4",
"profile": "https://github.com/vibhory2j",
"contributions": [
"bug"
]
},
{
"login": "Ramel0921",
"name": "Ramel0921",
"avatar_url": "https://avatars.githubusercontent.com/u/104978096?v=4",
"profile": "https://github.com/Ramel0921",
"contributions": [
"bug"
]
},
{
"login": "flyhard",
"name": "Per Abich",
"avatar_url": "https://avatars.githubusercontent.com/u/409466?v=4",
"profile": "https://github.com/flyhard",
"contributions": [
"code"
]
},
{
"login": "filipponova",
"name": "Filippo Nova",
"avatar_url": "https://avatars.githubusercontent.com/u/12506636?v=4",
"profile": "https://github.com/filipponova",
"contributions": [
"bug"
]
},
{
"login": "dalizi007",
"name": "dalizi007",
"avatar_url": "https://avatars.githubusercontent.com/u/90743616?v=4",
"profile": "https://github.com/dalizi007",
"contributions": [
"code"
]
},
{
"login": "shiomiyan",
"name": "shiomiyan",
"avatar_url": "https://avatars.githubusercontent.com/u/35842766?v=4",
"profile": "https://github.com/shiomiyan",
"contributions": [
"doc"
]
},
{
"login": "lgemeinhardt",
"name": "lgemeinhardt",
"avatar_url": "https://avatars.githubusercontent.com/u/1395165?v=4",
"profile": "https://github.com/lgemeinhardt",
"contributions": [
"bug"
]
},
{
"login": "HaelC",
"name": "Haoliang Chen",
"avatar_url": "https://avatars.githubusercontent.com/u/16898273?v=4",
"profile": "https://haelchan.me/",
"contributions": [
"bug"
]
},
{
"login": "FSchliephacke",
"name": "FSchliephacke",
"avatar_url": "https://avatars.githubusercontent.com/u/10260493?v=4",
"profile": "https://github.com/FSchliephacke",
"contributions": [
"bug"
]
},
{
"login": "stokpop",
"name": "Peter Paul Bakker",
"avatar_url": "https://avatars.githubusercontent.com/u/8797018?v=4",
"profile": "https://www.stokpop.nl/",
"contributions": [
"code"
]
},
{
"login": "ASBrouwers",
"name": "ASBrouwers",
"avatar_url": "https://avatars.githubusercontent.com/u/23551289?v=4",
"profile": "https://github.com/ASBrouwers",
"contributions": [
"code"
]
},
{
"login": "341816041",
"name": "茅延安",
"avatar_url": "https://avatars.githubusercontent.com/u/100549608?v=4",
"profile": "https://github.com/341816041",
"contributions": [
"code"
]
},
{
"login": "matthargett",
"name": "Matt Hargett",
"avatar_url": "https://avatars.githubusercontent.com/u/1550766?v=4",
"profile": "https://twitter.com/syke",
"contributions": [
"code",
"financial"
]
}
],
"contributorsPerLine": 7,
Expand Down
3 changes: 3 additions & 0 deletions .ci/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -244,12 +244,15 @@ ${rendered_release_notes}"
# Runs the dogfood ruleset with the currently built pmd against itself
#
function pmd_ci_dogfood() {
local mpmdVersion=()
./mvnw versions:set -DnewVersion="${PMD_CI_MAVEN_PROJECT_VERSION}-dogfood" -DgenerateBackupPoms=false
sed -i 's/<version>[0-9]\{1,\}\.[0-9]\{1,\}\.[0-9]\{1,\}.*<\/version>\( *<!-- pmd.dogfood.version -->\)/<version>'"${PMD_CI_MAVEN_PROJECT_VERSION}"'<\/version>\1/' pom.xml
if [ "${PMD_CI_MAVEN_PROJECT_VERSION}" = "7.0.0-SNAPSHOT" ]; then
sed -i 's/pmd-dogfood-config\.xml/pmd-dogfood-config7.xml/' pom.xml
mpmdVersion=(-Denforcer.skip=true -Dpmd.plugin.version=3.18.0-pmd7-SNAPSHOT)
fi
./mvnw verify --show-version --errors --batch-mode --no-transfer-progress "${PMD_MAVEN_EXTRA_OPTS[@]}" \
"${mpmdVersion[@]}" \
-DskipTests \
-Dmaven.javadoc.skip=true \
-Dmaven.source.skip=true \
Expand Down
39 changes: 38 additions & 1 deletion .ci/git-repo-sync.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function git_repo_sync() {
pmd_ci_log_group_start "Git Sync"
git remote add pmd-sf "${PMD_SF_USER}@git.code.sf.net:/p/pmd/code"
if [ -n "${PMD_CI_BRANCH}" ]; then
git push pmd-sf "${PMD_CI_BRANCH}:${PMD_CI_BRANCH}"
retry 5 git push pmd-sf "${PMD_CI_BRANCH}:${PMD_CI_BRANCH}"
pmd_ci_log_success "Successfully pushed ${PMD_CI_BRANCH} to sourceforge"
elif [ -n "${PMD_CI_TAG}" ]; then
git push pmd-sf tag "${PMD_CI_TAG}"
Expand All @@ -39,6 +39,43 @@ function git_repo_sync() {
pmd_ci_log_group_end
}


#
# From: https://gist.github.com/sj26/88e1c6584397bb7c13bd11108a579746
#
# Retry a command up to a specific number of times until it exits successfully,
# with exponential back off.
#
# $ retry 5 echo Hello
# Hello
#
# $ retry 5 false
# Retry 1/5 exited 1, retrying in 1 seconds...
# Retry 2/5 exited 1, retrying in 2 seconds...
# Retry 3/5 exited 1, retrying in 4 seconds...
# Retry 4/5 exited 1, retrying in 8 seconds...
# Retry 5/5 exited 1, no more retries left.
#
function retry {
local retries=$1
shift

local count=0
until "$@"; do
exit=$?
wait=$((2 ** $count))
count=$(($count + 1))
if [ $count -lt $retries ]; then
echo "Retry $count/$retries exited $exit, retrying in $wait seconds..."
sleep $wait
else
echo "Retry $count/$retries exited $exit, no more retries left."
return $exit
fi
done
return 0
}

git_repo_sync

exit 0
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
run: |
echo "LANG=en_US.UTF-8" >> $GITHUB_ENV
echo "MAVEN_OPTS=-Dmaven.wagon.httpconnectionManager.ttlSeconds=180 -Dmaven.wagon.http.retryHandler.count=3 -DautoReleaseAfterClose=true -DstagingProgressTimeoutMinutes=30" >> $GITHUB_ENV
echo "PMD_CI_SCRIPTS_URL=https://raw.githubusercontent.com/pmd/build-tools/17/scripts" >> $GITHUB_ENV
echo "PMD_CI_SCRIPTS_URL=https://raw.githubusercontent.com/pmd/build-tools/18/scripts" >> $GITHUB_ENV
- name: Check Environment
shell: bash
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/git-repo-sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
shell: bash
run: |
echo "LANG=en_US.UTF-8" >> $GITHUB_ENV
echo "PMD_CI_SCRIPTS_URL=https://raw.githubusercontent.com/pmd/build-tools/17/scripts" >> $GITHUB_ENV
echo "PMD_CI_SCRIPTS_URL=https://raw.githubusercontent.com/pmd/build-tools/18/scripts" >> $GITHUB_ENV
- name: Sync
run: .ci/git-repo-sync.sh
shell: bash
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/troubleshooting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
run: |
echo "LANG=en_US.UTF-8" >> $GITHUB_ENV
echo "MAVEN_OPTS=-Dmaven.wagon.httpconnectionManager.ttlSeconds=180 -Dmaven.wagon.http.retryHandler.count=3 -DstagingProgressTimeoutMinutes=30" >> $GITHUB_ENV
echo "PMD_CI_SCRIPTS_URL=https://raw.githubusercontent.com/pmd/build-tools/17/scripts" >> $GITHUB_ENV
echo "PMD_CI_SCRIPTS_URL=https://raw.githubusercontent.com/pmd/build-tools/18/scripts" >> $GITHUB_ENV
- name: Check Environment
shell: bash
run: |
Expand Down
4 changes: 2 additions & 2 deletions .mvn/wrapper/maven-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.5/apache-maven-3.8.5-bin.zip
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.6/apache-maven-3.8.6-bin.zip
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.1/maven-wrapper-3.1.1.jar
28 changes: 14 additions & 14 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ GEM
faraday-em_http (1.0.0)
faraday-em_synchrony (1.0.0)
faraday-excon (1.1.0)
faraday-http-cache (2.2.0)
faraday-http-cache (2.4.0)
faraday (>= 0.8)
faraday-httpclient (1.0.1)
faraday-multipart (1.0.3)
multipart-post (>= 1.2, < 3)
faraday-multipart (1.0.4)
multipart-post (~> 2)
faraday-net_http (1.0.1)
faraday-net_http_persistent (1.2.0)
faraday-patron (1.0.0)
Expand All @@ -65,15 +65,15 @@ GEM
liquid (5.3.0)
logger-colors (1.0.0)
mini_portile2 (2.8.0)
multipart-post (2.1.1)
multipart-post (2.2.3)
nap (1.1.0)
no_proxy_fix (0.1.2)
nokogiri (1.13.6)
nokogiri (1.13.7)
mini_portile2 (~> 2.8.0)
racc (~> 1.4)
octokit (4.22.0)
faraday (>= 0.9)
sawyer (~> 0.8.0, >= 0.5.3)
octokit (4.25.1)
faraday (>= 1, < 3)
sawyer (~> 0.9)
open4 (1.3.4)
pmdtester (1.5.1)
differ (~> 0.1)
Expand All @@ -87,20 +87,20 @@ GEM
racc (1.6.0)
rchardet (1.8.0)
rexml (3.2.5)
rouge (3.28.0)
rouge (3.29.0)
ruby2_keywords (0.0.5)
rufus-scheduler (3.8.1)
rufus-scheduler (3.8.2)
fugit (~> 1.1, >= 1.1.6)
safe_yaml (1.0.5)
sawyer (0.8.2)
sawyer (0.9.2)
addressable (>= 2.3.5)
faraday (> 0.8, < 2.0)
faraday (>= 0.17.3, < 3)
slop (4.9.2)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
tzinfo (2.0.4)
tzinfo (2.0.5)
concurrent-ruby (~> 1.0)
unicode-display_width (2.1.0)
unicode-display_width (2.2.0)

PLATFORMS
ruby
Expand Down
8 changes: 8 additions & 0 deletions do-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,14 @@ export RELEASE_VERSION
export DEVELOPMENT_VERSION
export CURRENT_BRANCH

# check for SNAPSHOT version of pmd.build-tools.version
BUILD_TOOLS_VERSION=$(./mvnw org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=pmd.build-tools.version -q -DforceStdout)
BUILD_TOOLS_VERSION_RELEASE=${BUILD_TOOLS_VERSION%-SNAPSHOT}
if [ "${BUILD_TOOLS_VERSION}" != "${BUILD_TOOLS_VERSION_RELEASE}" ]; then
echo "Error: version pmd.build-tools.version is ${BUILD_TOOLS_VERSION} - snapshot is not allowed"
exit 1
fi

RELEASE_RULESET="pmd-core/src/main/resources/rulesets/releases/${RELEASE_VERSION//\./}.xml"

echo "* Update date info in **docs/_config.yml**."
Expand Down

0 comments on commit 2cfdc9c

Please sign in to comment.