Skip to content
This repository was archived by the owner on Aug 31, 2023. It is now read-only.

Commit 5d541b1

Browse files
committed
Begin work on hiding MRs based on their pipeline status
1 parent aff338c commit 5d541b1

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

js/content.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@
132132
this.baseUrl = location.protocol + '//' + location.host;
133133
this.baseApiUrl = this.baseUrl + '/api/v4/';
134134
this.userAuthenticated = this.isUserAuthenticated();
135+
this.pipelineFeatureEnabled = this.isPipelineFeatureEnabled();
135136
this.apiClient = new GitLabApiClient(this.baseApiUrl, this.getCsrfToken());
136137

137138
this.currentMergeRequestIds = this.getCurrentMergeRequestIds();
@@ -184,6 +185,13 @@
184185
return document.querySelector('.navbar-nav .header-user') ? true : false;
185186
}
186187

188+
/**
189+
* Determines if the project do uses the Gitlab "pipeline" feature.
190+
*/
191+
isPipelineFeatureEnabled() {
192+
return document.querySelector('.nav-sidebar .shortcuts-pipelines') ? true : false;
193+
}
194+
187195
/**
188196
* Gets all Merge Requests IDs that are currently displayed.
189197
*/

scripts/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
MANIFEST_FILE = {
22
'manifest_version': 2,
33
'name': 'GitLab Merge Requests lists enhancer',
4-
'version': '1.5.0',
4+
'version': '1.6.0',
55
'description': 'An extension that enhance all Merge Requests lists on any instance of Gitlab and GitLab.com.',
66
'homepage_url': 'https://github.com/EpocDotFr/gitlab-merge-requests-lists-enhancer',
77
'author': 'Maxime \'Epoc\' G.',

0 commit comments

Comments
 (0)