Skip to main content

lice-tddschn

Fork of Lice, original license.

lice-tddschn is made faster by not importing the large pkg_resources module.

Lice generates license files. No more hunting down licenses from other projects.

Installation

pipx

This is the recommended installation method.

$ pipx install lice-tddschn

pip

$ pip install lice-tddschn

Overview

Generate a BSD-3 license, the default:

$ lice
Copyright (c) 2013, Jeremy Carbaugh

All rights reserved.

Redistribution and use in source and binary forms, with or without modification,
...

Generate an MIT license:

$ lice mit
The MIT License (MIT)
Copyright (c) 2013 Jeremy Carbaugh

Permission is hereby granted, free of charge, to any person obtaining a copy
...

Generate a BSD-3 license, specifying the year and organization to be used:

$ lice -y 2012 -o "Sunlight Foundation"
Copyright (c) 2012, Sunlight Foundation

All rights reserved.

Redistribution and use in source and binary forms, with or without modification,
...

Generate a BSD-3 license, formatted for python source file:

$ lice -l py

# Copyright (c) 2012, Sunlight Foundation
#
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
...

Generate a python source file with a BSD-3 license commented in the header:

$ lice -l py -f test
$ ls
test.py
$ cat test.py

# Copyright (c) 2012, Sunlight Foundation
#
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
...

Generate a source file (language detected by -f extension):

$ lice -f test.c && cat test.c
/*
 * Copyright (c) 2012, Sunlight Foundation
 *
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without modification,
...

If organization is not specified, lice will first attempt to use git config to find your name. If not found, it will use the value of the $USER environment variable. If the project name is not specified, the name of the current directory is used. Year will default to the current year.

You can see what variables are available to you for any of the licenses:

$ lice --vars mit
The mit license template contains the following variables:
  year
  organization

I want XXXXXXXXX license in here!

Great! Is it a license that is commonly used? If so, open an issue or, if you are feeling generous, fork and submit a pull request.

Usage

usage: lice [-h] [-o ORGANIZATION] [-p PROJECT] [-t TEMPLATE_PATH] [-y YEAR]
            [--vars] [license]

positional arguments:
  license               the license to generate, one of: agpl3, apache, bsd2,
                        bsd3, cddl, cc0, epl, gpl2, gpl3, lgpl, mit, mpl

optional arguments:
  -h, --help            show this help message and exit
  -o ORGANIZATION, --org ORGANIZATION
                        organization, defaults to .gitconfig or
                        os.environ["USER"]
  -p PROJECT, --proj PROJECT
                        name of project, defaults to name of current directory
  -t TEMPLATE_PATH, --template TEMPLATE_PATH
                        path to license template file
  -y YEAR, --year YEAR  copyright year
  -l LANGUAGE, --language LANGUAGE
                        format output for language source file, one of: js, f,
                        css, c, m, java, py, cc, h, html, lua, erl, rb, sh,
                        f90, hpp, cpp, pl, txt [default is not formatted (txt)]
  -f OFILE, --file OFILE Name of the output source file (with -l, extension can be omitted)
  --vars                list template variables for specified license

Develop

$ git clone https://github.com/tddschn/lice-tddschn.git
$ cd lice-tddschn
$ poetry install

Metadata

Release files for lice-tddschn 0.1.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lice-tddschn 0.1.5
File Size Uploaded
lice-tddschn-0.1.5.tar.gz 74.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for lice-tddschn 0.1.5
File Interpreter ABI Platform
lice_tddschn-0.1.5-py3-none-any.whl Python 3 none any Details

Total release size: 195.7 kB

Release files / lice-tddschn-0.1.5.tar.gz

Download URL lice-tddschn-0.1.5.tar.gz
Size 74.7 kB
Tags Source
SHA-256 checksum
How to use checksums
bb059eb187e67231a6506c1d203a08455a17e98341bc47cb81b8f3fc611beac2
BLAKE2b-256 checksum
How to use checksums
227fd2ddf75d7e262cab1000bf9a97143dae36546e374ee031aa40b90266018e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.13 CPython/3.10.4 Darwin/21.4.0

Release files / lice_tddschn-0.1.5-py3-none-any.whl

Download URL lice_tddschn-0.1.5-py3-none-any.whl
Size 121.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9c17249d43592408565d534366caf6e503c0261bd13f80868730fae3e9741484
BLAKE2b-256 checksum
How to use checksums
532cc2c446a8ecee0f800e6598c337575e77fe5611278506b6c86c90ff230c90
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.13 CPython/3.10.4 Darwin/21.4.0

Release history Release notifications | RSS feed

This release

0.1.5 This release

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page