feat: add license headers (+spdx id)
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
leo 2023-05-20 20:15:57 +02:00
parent 9159cc315e
commit 3a2f85f683
Signed by: wanderer
SSH Key Fingerprint: SHA256:Dp8+iwKHSlrMEHzE3bJnPng70I7LEsa3IJXRH/U+idQ
50 changed files with 170 additions and 0 deletions

@ -1,4 +1,7 @@
--- ---
# Copyright 2023 wanderer <a_mirre at utb dot cz>
# SPDX-License-Identifier: AGPL-3.0-only
kind: pipeline kind: pipeline
type: docker type: docker
name: test archlinux name: test archlinux

@ -1,3 +1,6 @@
# Copyright 2023 wanderer <a_mirre at utb dot cz>
# SPDX-License-Identifier: AGPL-3.0-only
--- ---
failure-threshold: warning failure-threshold: warning
... ...

@ -22,3 +22,13 @@ repos:
rev: v0.0.1 rev: v0.0.1
hooks: hooks:
- id: hadolint-container - id: hadolint-container
- repo: local
hooks:
- id: addlicense
name: addlicence -check
entry: >
go run github.com/google/addlicense@v1.1.1 -check -v
pass_filenames: true
types_or: ["go", "yaml", "javascript", "dockerfile"]
exclude: "^(devenv.yaml|assets/.*|templates/.*)$"
language: system

@ -1,4 +1,7 @@
# syntax=docker/dockerfile-upstream:master-labs # syntax=docker/dockerfile-upstream:master-labs
# Copyright 2023 wanderer <a_mirre at utb dot cz>
# SPDX-License-Identifier: AGPL-3.0-only
FROM docker.io/library/alpine:3.18.0 as dhall-cache FROM docker.io/library/alpine:3.18.0 as dhall-cache
ENV XDG_CACHE_HOME=/var/cache ENV XDG_CACHE_HOME=/var/cache
ENV DHALL_VERSION=1.42.0 ENV DHALL_VERSION=1.42.0

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package app package app
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package app package app
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package app package app
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package app package app
import "errors" import "errors"

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package app package app
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package app package app
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package settings package settings
import "flag" import "flag"

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package settings package settings
import ( import (

5
bs.js

@ -1,3 +1,8 @@
/**
* Copyright 2023 wanderer <a_mirre at utb dot cz>
* SPDX-License-Identifier: AGPL-3.0-only
*/
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package config package config
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package config package config
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package main package main
import "embed" import "embed"

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package ent package ent
//go:generate go run -mod=mod entgo.io/ent/cmd/ent generate ./schema //go:generate go run -mod=mod entgo.io/ent/cmd/ent generate ./schema

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package schema package schema
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package schema package schema
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package schema package schema
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package main package main
import "errors" import "errors"

3
gen.go

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package main package main
//go:generate npm i //go:generate npm i

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
type Iconier interface { type Iconier interface {

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import moduser "git.dotya.ml/mirre-mt/pcmt/modules/user" import moduser "git.dotya.ml/mirre-mt/pcmt/modules/user"

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package handlers package handlers
type userSignin struct { type userSignin struct {

@ -47,6 +47,16 @@ prod: tw build
gen: gen:
go generate -v ./ent go generate -v ./ent
# add licence headers to source code files.
addlicense:
go run github.com/google/addlicense@v1.1.1 \
-v -s=only \
-c "wanderer <a_mirre at utb dot cz>" \
-l "AGPL-3.0-only" \
-ignore "tmp/**" -ignore "assets/**" -ignore "config/testdata/**" \
-ignore "*.dhall" -ignore "node_modules/**" -ignore "devenv.yaml" \
.
# start pg. # start pg.
dbstart: dbstart:
mkdir -p tmp/db mkdir -p tmp/db

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package main package main
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package bluemonday package bluemonday
import "github.com/microcosm-cc/bluemonday" import "github.com/microcosm-cc/bluemonday"

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package db package db
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package funcmap package funcmap
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package funcmap package funcmap
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package password package password
import "golang.org/x/crypto/bcrypt" import "golang.org/x/crypto/bcrypt"

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package template package template
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package template package template
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package template package template
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package user package user
// CtxKey serves as a key to context values for this package. // CtxKey serves as a key to context values for this package.

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package user package user
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package user package user
import ( import (

3
run.go

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package main package main
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package main package main
import ( import (

@ -1,3 +1,6 @@
// Copyright 2023 wanderer <a_mirre at utb dot cz>
// SPDX-License-Identifier: AGPL-3.0-only
package slogging package slogging
import ( import (

@ -1,3 +1,8 @@
/**
* Copyright 2023 wanderer <a_mirre at utb dot cz>
* SPDX-License-Identifier: AGPL-3.0-only
*/
module.exports = { module.exports = {
multipass: true, multipass: true,
plugins: [ plugins: [

@ -1,3 +1,8 @@
/**
* Copyright 2023 wanderer <a_mirre at utb dot cz>
* SPDX-License-Identifier: AGPL-3.0-only
*/
/** @type {import('tailwindcss').Config} */ /** @type {import('tailwindcss').Config} */
module.exports = { module.exports = {
content: ["./templates/**.{tmpl,html}"], content: ["./templates/**.{tmpl,html}"],