Skip to content
This repository was archived by the owner on Jun 19, 2025. It is now read-only.

Commit f78a862

Browse files
authored
Merge pull request #153 from NodeSecure/maintenance
Adding security policy and updating badges
2 parents 57d68a1 + 789d90e commit f78a862

File tree

2 files changed

+30
-10
lines changed

2 files changed

+30
-10
lines changed

README.md

Lines changed: 25 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,18 @@
11
# Gitlab
2-
![version](https://img.shields.io/badge/dynamic/json.svg?url=https://raw.githubusercontent.com/NodeSecure/gitlab/master/package.json&query=$.version&label=Version)
3-
[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://github.com/NodeSecure/gitlab/commit-activity)
2+
3+
![version](https://img.shields.io/badge/dynamic/json.svg?style=for-the-badge&url=https://raw.githubusercontent.com/NodeSecure/gitlab/master/package.json&query=$.version&label=Version)
4+
[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg?style=for-the-badge)](https://github.com/NodeSecure/gitlab/commit-activity)
45
[![OpenSSF
5-
Scorecard](https://api.securityscorecards.dev/projects/github.com/NodeSecure/gitlab/badge)](https://api.securityscorecards.dev/projects/github.com/NodeSecure/gitlab)
6-
![MIT](https://img.shields.io/github/license/mashape/apistatus.svg)
7-
![size](https://img.shields.io/github/repo-size/NodeSecure/gitlab)
8-
![known vulnerabilities](https://img.shields.io/snyk/vulnerabilities/github/NodeSecure/gitlab)
9-
![build](https://img.shields.io/github/actions/workflow/status/NodeSecure/gitlab/node.js.yml)
6+
Scorecard](https://api.securityscorecards.dev/projects/github.com/NodeSecure/gitlab/badge?style=for-the-badge)](https://api.securityscorecards.dev/projects/github.com/NodeSecure/gitlab)
7+
![MIT](https://img.shields.io/github/license/mashape/apistatus.svg?style=for-the-badge)
8+
![size](https://img.shields.io/github/repo-size/NodeSecure/gitlab?style=for-the-badge)
9+
![known vulnerabilities](https://img.shields.io/snyk/vulnerabilities/github/NodeSecure/gitlab?style=for-the-badge)
10+
![build](https://img.shields.io/github/actions/workflow/status/NodeSecure/gitlab/node.js.yml?style=for-the-badge)
1011

1112
Download and (optionaly) extract gitlab repository archive.
1213

1314
## Requirements
15+
1416
- [Node.js](https://nodejs.org/en/) v16 or higher
1517

1618
## Getting Started
@@ -24,6 +26,7 @@ $ yarn add @nodesecure/gitlab
2426
```
2527

2628
## Usage example
29+
2730
```js
2831
import * as gitlab from "@nodesecure/gitlab";
2932

@@ -33,6 +36,7 @@ console.log(is.location);
3336
```
3437

3538
## API
39+
3640
```ts
3741
export interface DownloadOptions {
3842
/**
@@ -63,7 +67,7 @@ export type ExtractOptions = DownloadOptions & {
6367
* @default true
6468
*/
6569
removeArchive?: boolean;
66-
}
70+
};
6771

6872
export interface DownloadResult {
6973
/** Archive or repository location on disk */
@@ -76,13 +80,20 @@ export interface DownloadResult {
7680
branch: string;
7781
}
7882

79-
export function download(repo: string, options?: DownloadOptions): Promise<DownloadResult>;
80-
export function downloadAndExtract(repo: string, options?: ExtractOptions): Promise<DownloadResult>;
83+
export function download(
84+
repo: string,
85+
options?: DownloadOptions
86+
): Promise<DownloadResult>;
87+
export function downloadAndExtract(
88+
repo: string,
89+
options?: ExtractOptions
90+
): Promise<DownloadResult>;
8191
export function setToken(gitlabToken: string): void;
8292
export function setUrl(gitlabUrl: string | URL): void;
8393
```
8494

8595
### Private repositories
96+
8697
To work with private repositories you can either setup a `GITLAB_TOKEN` system variable or use `setToken` method:
8798

8899
```js
@@ -92,6 +103,7 @@ gitlab.setToken("...");
92103
```
93104

94105
### Custom gitlab URL
106+
95107
To work with a custom gitlab instance you can either setup a `GITLAB_URL` system variable or use `setUrl` method:
96108

97109
```js
@@ -103,7 +115,9 @@ gitlab.setUrl("...");
103115
## Contributors ✨
104116

105117
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
118+
106119
[![All Contributors](https://img.shields.io/badge/all_contributors-3-orange.svg?style=flat-square)](#contributors-)
120+
107121
<!-- ALL-CONTRIBUTORS-BADGE:END -->
108122

109123
Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
@@ -125,4 +139,5 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
125139
<!-- ALL-CONTRIBUTORS-LIST:END -->
126140

127141
## License
142+
128143
MIT

SECURITY.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Reporting Security Issues
2+
3+
To report a security issue, please [publish a private security advisory](https://github.com/NodeSecure/gitlab/security/advisories) with a description of the issue, the steps you took to create the issue, affected versions, and, if known, mitigations for the issue.
4+
5+
Our vulnerability management team will respond within one week. If the issue is confirmed as a vulnerability, we will open a Security Advisory and acknowledge your contributions as part of it. This project follows a 90 day disclosure timeline.

0 commit comments

Comments
 (0)