Add license headers across the project
This commit is contained in:
parent
8c3da11996
commit
8bfaf598af
738 changed files with 2695 additions and 378 deletions
|
@ -1,3 +1,6 @@
|
|||
// Copyright 2020 Signal Messenger, LLC
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
/* eslint-disable no-console */
|
||||
const assert = require('assert');
|
||||
const fs = require('fs');
|
||||
|
@ -65,6 +68,20 @@ async function getMarkdownForDependency(dependencyName) {
|
|||
].join('\n');
|
||||
}
|
||||
|
||||
function licenseComment() {
|
||||
const fileCreatedYear = 2020;
|
||||
const currentYear = new Date().getFullYear();
|
||||
const yearRange =
|
||||
fileCreatedYear === currentYear
|
||||
? fileCreatedYear
|
||||
: `${fileCreatedYear}-${currentYear}`;
|
||||
|
||||
return [
|
||||
`<!-- Copyright ${yearRange} Signal Messenger, LLC -->`,
|
||||
'<!-- SPDX-License-Identifier: AGPL-3.0-only -->',
|
||||
].join('\n');
|
||||
}
|
||||
|
||||
async function main() {
|
||||
assert.deepStrictEqual(
|
||||
Object.keys(optionalDependencies),
|
||||
|
@ -90,6 +107,7 @@ async function main() {
|
|||
);
|
||||
|
||||
const unformattedOutput = [
|
||||
licenseComment(),
|
||||
'# Acknowledgments',
|
||||
'',
|
||||
'Signal Desktop makes use of the following open source projects.',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue