Fix GitLab URLs to point to the correct project page

GitLab 16.0 removes support for URLs that don't contain /-/ after the
repository name, so the report bug feature and various links we had in
the source (including the git-fixes script) would lead to a 404 error.

See GitLab docs for deprecation/removal notice:
https://docs.gitlab.com/ee/update/deprecations.html?removal_milestone=16.0#legacy-urls-replaced-or-removed

(Cherry-picked from 20ec8ed303)

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/14759
This commit is contained in:
Ian McInerney 2023-05-17 11:23:00 +01:00
parent df698b9433
commit 17c27d1176
8 changed files with 33 additions and 8 deletions

View File

@ -14,7 +14,7 @@ default:
##########################################################################
# The variable CI_COMMIT_BEFORE_SHA is not available in normal merge requests
# so we must build the commit hash ourselves, see:
# https://gitlab.com/gitlab-org/gitlab/issues/12850
# https://gitlab.com/gitlab-org/gitlab/-/issues/12850
test_formatting:
stage: test
needs: []

25
.gitlab/mr_formatting.yml Normal file
View File

@ -0,0 +1,25 @@
##########################################################################
# Test the formatting in a merge request using clang-format
##########################################################################
# The variable CI_COMMIT_BEFORE_SHA is not available in normal merge requests
# so we must build the commit hash ourselves, see:
# https://gitlab.com/gitlab-org/gitlab/-/issues/12850
test_formatting:
stage: test
needs: []
rules:
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
allow_failure: true
before_script:
# We must manually add the KiCad remote to ensure it is named sensibly
- git remote add product https://gitlab.com/kicad/code/kicad.git
- git remote add source ${CI_MERGE_REQUEST_SOURCE_PROJECT_URL}.git
- git fetch -n product
- git fetch -n source
# Get the SHAs of the commits
- "TARGET_HEAD_SHA=$(git rev-parse product/${CI_MERGE_REQUEST_TARGET_BRANCH_NAME})"
- "SOURCE_HEAD_SHA=$(git rev-parse source/${CI_MERGE_REQUEST_SOURCE_BRANCH_NAME})"
- "MERGE_BASE_SHA=$(git merge-base ${TARGET_HEAD_SHA} ${SOURCE_HEAD_SHA})"
script:
- echo "Testing formatting from commit ${MERGE_BASE_SHA}"
- ./tools/check_coding.sh --diff --ci --commit ${MERGE_BASE_SHA}

View File

@ -28,7 +28,7 @@
# GitLab supports displaying the results in the GUI through JUNIT artifacts
# (https://docs.gitlab.com/ee/ci/junit_test_reports.html)
# so we upload the JUNIT results. Note that there is a bug with how paths
# are processed in the junit report (https://gitlab.com/gitlab-org/gitlab/issues/23835)
# are processed in the junit report (https://gitlab.com/gitlab-org/gitlab/-/issues/23835)
# so we can't use a glob and have to list out each hierarchy separately.
artifacts:
reports:

View File

@ -258,8 +258,8 @@ void RC_TREE_MODEL::rebuildModel( std::shared_ptr<RC_ITEMS_PROVIDER> aProvider,
// The fastest method to update wxDataViewCtrl is to rebuild from
// scratch by calling Cleared(). Linux requires to reassociate model to
// display data, but Windows will create multiple associations.
// On MacOS, this crashes KiCad. See https://gitlab.com/kicad/code/kicad/issues/3666
// and https://gitlab.com/kicad/code/kicad/issues/3653
// On MacOS, this crashes KiCad. See https://gitlab.com/kicad/code/kicad/-/issues/3666
// and https://gitlab.com/kicad/code/kicad/-/issues/3653
m_view->AssociateModel( this );
#endif

View File

@ -50,7 +50,7 @@
/// URL to launch a new issue with pre-populated description
wxString COMMON_CONTROL::m_bugReportUrl =
wxS( "https://gitlab.com/kicad/code/kicad/issues/new?issuable_template=bare&issue[description]=%s" );
wxS( "https://gitlab.com/kicad/code/kicad/-/issues/new?issuable_template=bare&issue[description]=%s" );
/// Issue template to use for reporting bugs (this should not be translated)

View File

@ -912,7 +912,7 @@ ATEXT6::ATEXT6( ALTIUM_PARSER& aReader, std::map<uint32_t, wxString>& aStringTab
textposition = static_cast<ALTIUM_TEXT_POSITION>( aReader.Read<uint8_t>() );
/**
* In Altium 14 (subrecord1 == 230) only left bottom is valid? I think there is a bit missing.
* https://gitlab.com/kicad/code/kicad/merge_requests/60#note_274913397
* https://gitlab.com/kicad/code/kicad/-/merge_requests/60#note_274913397
*/
if( subrecord1 <= 230 )
textposition = ALTIUM_TEXT_POSITION::LEFT_BOTTOM;

View File

@ -5,7 +5,7 @@ It is licensed under the Boost Software License, with the license text in this d
The reasons for creating a custom libcontext/coroutines library instead of using the Boost versions are described in several places. It was first introduced and discussed on the mailing list here: https://www.mail-archive.com/kicad-developers@lists.launchpad.net/msg23327.html
From https://gitlab.com/kicad/code/kicad/issues/237:
From https://gitlab.com/kicad/code/kicad/-/issues/237:
---------------

View File

@ -7,7 +7,7 @@
fixes = "!f() { \
COMMIT_MSG=$(git log -n1 --format=%B); \
git commit --amend -m \"${COMMIT_MSG}\n\nFixes https://gitlab.com/kicad/code/kicad/issues/$1\"; \
git commit --amend -m \"${COMMIT_MSG}\n\nFixes https://gitlab.com/kicad/code/kicad/-/issues/$1\"; \
}; f"