├── harvey ├── __init__.py ├── licences_tldr.json ├── licenses.json ├── get_tldr.py ├── harvey.py └── summary.json ├── requirements.txt ├── README.rst ├── MANIFEST.in ├── .gitignore ├── setup.py ├── LICENSE └── README.md /harvey/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | colorama==0.3.3 2 | docopt>=0.6.2 3 | requests>=2.8.0 4 | -------------------------------------------------------------------------------- /README.rst: -------------------------------------------------------------------------------- 1 | Harvey 2 | ===== 3 | 4 | Harvey is a command line legal expert who manages license for you. -------------------------------------------------------------------------------- /MANIFEST.in: -------------------------------------------------------------------------------- 1 | include *.md 2 | include *.rst 3 | include *.txt 4 | include *.json 5 | 6 | exclude .gitignore 7 | 8 | global-exclude *.pyc 9 | global-exclude .DS_Store -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.pyc 2 | config.py 3 | README 4 | README.txt 5 | 6 | # Distribution / packaging 7 | .Python 8 | env/ 9 | bin/ 10 | build/ 11 | develop-eggs/ 12 | dist/ 13 | eggs/ 14 | lib/ 15 | lib64/ 16 | parts/ 17 | sdist/ 18 | var/ 19 | *.egg-info/ 20 | .installed.cfg 21 | *.egg 22 | 23 | # Installer logs 24 | pip-log.txt 25 | pip-delete-this-directory.txt 26 | -------------------------------------------------------------------------------- /harvey/licences_tldr.json: -------------------------------------------------------------------------------- 1 | { 2 | "apache-2.0": "https://tldrlegal.com/l/apache2", 3 | "mit": "https://tldrlegal.com/l/mit", 4 | "gpl-3.0": "https://tldrlegal.com/l/gpl-3.0", 5 | "gpl-2.0": "https://tldrlegal.com/l/gpl2", 6 | "bsd-2-clause": "https://tldrlegal.com/l/freebsd", 7 | "bsd-3-clause": "https://tldrlegal.com/l/bsd3", 8 | "lgpl-2.1": "https://tldrlegal.com/l/lgpl2", 9 | "lgpl-3.0": "https://tldrlegal.com/l/lgpl-3.0", 10 | "mpl-2.0": "https://tldrlegal.com/l/mpl-2.0", 11 | "unlicense": "https://tldrlegal.com/license/unlicense", 12 | "cc0-1.0": "https://tldrlegal.com/l/cc0-1.0", 13 | "epl-1.0": "https://tldrlegal.com/l/epl", 14 | "isc": "https://tldrlegal.com/l/isc", 15 | "agpl-3.0": "https://tldrlegal.com/l/agpl3", 16 | "artistic-2.0": "https://tldrlegal.com/l/artistic" 17 | } -------------------------------------------------------------------------------- /harvey/licenses.json: -------------------------------------------------------------------------------- 1 | { 2 | "apache-2.0": "Apache License 2.0", 3 | "lgpl-3.0": "GNU Lesser General Public License v3.0", 4 | "gpl-2.0": "GNU General Public License v2.0", 5 | "mpl-2.0": "Mozilla Public License 2.0", 6 | "gpl-3.0": "GNU General Public License v3.0", 7 | "unlicense": "The Unlicense", 8 | "cc0-1.0": "Creative Commons Zero v1.0 Universal", 9 | "artistic-2.0": "Artistic License 2.0", 10 | "agpl-3.0": "GNU Affero General Public License v3.0", 11 | "isc": "ISC License", 12 | "lgpl-2.1": "GNU Lesser General Public License v2.1", 13 | "epl-1.0": "Eclipse Public License 1.0", 14 | "bsd-3-clause": "BSD 3-clause \"New\" or \"Revised\" License", 15 | "bsd-2-clause": "BSD 2-clause \"Simplified\" License", 16 | "mit": "MIT License" 17 | } -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | import os 4 | 5 | from setuptools import setup, find_packages 6 | 7 | # if you are not using vagrant, just delete os.link directly, 8 | # The hard link only saves a little disk space, so you should not care 9 | if os.environ.get('USER', '') == 'vagrant': 10 | del os.link 11 | 12 | 13 | setup( 14 | name='harvey', 15 | version='0.0.5', 16 | description='harvey helps you manage and choose license from command line', 17 | long_description=open('README.rst').read(), 18 | author='Archit Verma', 19 | author_email='architv07@gmail.com', 20 | license='MIT', 21 | keywords=['license', 'legal', 'github', 'command line', 'cli'], 22 | url='https://github.com/architv/harvey', 23 | packages=find_packages(exclude=['contrib', 'docs', 'tests']), 24 | package_data={ 25 | 'harvey': ['*.json'], 26 | }, 27 | install_requires=[ 28 | 'docopt>=0.6.2', 29 | 'requests>=2.8.0', 30 | 'colorama==0.3.3' 31 | ], 32 | entry_points={ 33 | 'console_scripts': [ 34 | 'harvey = harvey.harvey:main' 35 | ], 36 | } 37 | ) 38 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015 Archit Verma 4 | 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in all 14 | copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | SOFTWARE. 23 | -------------------------------------------------------------------------------- /harvey/get_tldr.py: -------------------------------------------------------------------------------- 1 | import re 2 | import json 3 | 4 | from bs4 import BeautifulSoup 5 | import requests 6 | 7 | RESOURCES = {} 8 | BASE_URL = "https://api.github.com" 9 | _HEADERS = {'Accept': 'application/vnd.github.drax-preview+json'} 10 | 11 | with open('licences_tldr.json', 'r') as f: 12 | RESOURCES = json.loads(f.read()) 13 | 14 | 15 | def get_summary(content): 16 | """Gets the summary of a license from tldrlegal.com""" 17 | soup = BeautifulSoup(content, "html.parser") 18 | summary = soup.find_all(attrs={ 19 | 'class': re.compile(r".*\bsummary-content\b.*")}) 20 | 21 | if summary[0].p.string is None: 22 | return summary[0].p.p.getText() 23 | return summary[0].p.getText() 24 | 25 | 26 | def get_rules(license): 27 | """Gets can, cannot and must rules from github license API""" 28 | 29 | can = [] 30 | cannot = [] 31 | must = [] 32 | req = requests.get("{base_url}/licenses/{license}".format( 33 | base_url=BASE_URL, license=license), headers=_HEADERS) 34 | 35 | if req.status_code == requests.codes.ok: 36 | data = req.json() 37 | can = data["permitted"] 38 | cannot = data["forbidden"] 39 | must = data["required"] 40 | 41 | return can, cannot, must 42 | 43 | 44 | def main(): 45 | """Gets all the license information and stores it in json format""" 46 | 47 | all_summary = {} 48 | 49 | for license in RESOURCES: 50 | 51 | req = requests.get(RESOURCES[license]) 52 | 53 | if req.status_code == requests.codes.ok: 54 | summary = get_summary(req.text) 55 | can, cannot, must = get_rules(license) 56 | 57 | all_summary[license] = { 58 | "summary": summary, 59 | "source": RESOURCES[license], 60 | "can": can, 61 | "cannot": cannot, 62 | "must": must 63 | } 64 | 65 | with open('summary.json', 'w+') as f: 66 | f.write(json.dumps(all_summary, indent=4)) 67 | 68 | 69 | if __name__ == '__main__': 70 | main() 71 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | harvey 2 | ===== 3 | [![PyPI version](https://badge.fury.io/py/harvey.svg)](https://badge.fury.io/py/harvey) 4 | 5 | ![](http://i.imgur.com/raSkNrr.png?1) 6 | 7 | Harvey is a command line legal expert who manages license for your open source project. 8 | 9 | ## Demo 10 | 11 | ![](http://i.imgur.com/gEKlzfv.gif?1) 12 | 13 | ## Features 14 | 15 | - Written in Python 16 | - Supports all Github-supported [`licenses`](https://github.com/architv/harvey#list-of-supported-licenses) 17 | - Works on Mac, Linux, Windows 18 | 19 | ## Installation 20 | 21 | 22 | ### Option 1: [Pip](https://pypi.python.org/pypi/harvey) 23 | 24 | ```bash 25 | $ pip install harvey 26 | ``` 27 | 28 | ### Option 2: From source 29 | 30 | ```bash 31 | $ git clone git@github.com:architv/harvey.git 32 | $ cd harvey/ 33 | $ python setup.py install 34 | ``` 35 | 36 | ####Note: 37 | 38 | Windows users might need to install [ansicon](https://github.com/adoxa/ansicon) for colorama to work correctly. 39 | 40 | ## Usage 41 | 42 | ### Get summary, can, cannot and must rules for a license 43 | 44 | ```bash 45 | $ harvey gpl-2.0 --tldr 46 | ``` 47 | 48 | ### Get a `LICENSE` for your git repo 49 | 50 | 51 | ```bash 52 | $ harvey mit # outputs mit license to stdout 53 | ``` 54 | 55 | ### Overwrite existing `LICENSE` 56 | 57 | ```bash 58 | $ harvey mit > LICENSE # saves a new mit LICENSE file 59 | ``` 60 | 61 | OR 62 | 63 | ```bash 64 | $ harvey --export mit # saves a new mit LICENSE file 65 | ``` 66 | 67 | 68 | ### List all licenses 69 | 70 | ```bash 71 | $ harvey ls # or `harvey list` 72 | ``` 73 | 74 | ### Help 75 | 76 | ```bash 77 | $ harvey --help 78 | ``` 79 | 80 | 81 | ### List of supported licenses 82 | 83 | * BSD 3-clause "New" or "Revised" License [bsd-3-clause] 84 | * GNU Lesser General Public License v3.0 [lgpl-3.0] 85 | * GNU General Public License v2.0 [gpl-2.0] 86 | * Mozilla Public License 2.0 [mpl-2.0] 87 | * GNU General Public License v3.0 [gpl-3.0] 88 | * The Unlicense [unlicense] 89 | * Creative Commons Zero v1.0 Universal [cc0-1.0] 90 | * Artistic License 2.0 [artistic-2.0] 91 | * GNU Affero General Public License v3.0 [agpl-3.0] 92 | * ISC License [isc] 93 | * GNU Lesser General Public License v2.1 [lgpl-2.1] 94 | * Eclipse Public License 1.0 [epl-1.0] 95 | * Apache License 2.0 [apache-2.0] 96 | * BSD 2-clause "Simplified" License [bsd-2-clause] 97 | * MIT License [mit] 98 | 99 | ## FAQ's 100 | 101 | #### How is this any better than [choose a license](http://choosealicense.com/licenses/) and [tldr legal](https://tldrlegal.com/)? 102 | 103 | * Harvey doesn't only let you select a license, it also helps you to add it to your project. So, doing something like: 104 | ```bash 105 | harvey apache-2.0 > LICENSE 106 | ``` 107 | will add the apache license in your project, with your user name, which you have setup in your `git config` settings 108 | 109 | * Yes, [choose a license](http://choosealicense.com/licenses/) also allows you to select a license. But since this is a CLI app, you can choose the license without breaking your workflow. Thus, it saves you time by not having to switch over to the browser. 110 | 111 | #### Still, it seems really unnecessary. 112 | 113 | Apart from what I have mentioned above, I wouldn't go as far as saying that harvey is absolutely essential to manage license for your open source project. I felt the need for the app because every time I had to add a license to my project I had to head over to the browser for a license template. So, I created harvey to allow me to add a license without breaking my workflow. 114 | 115 | 116 | ## Contributing 117 | 118 | #### Bug Reports & Feature Requests 119 | 120 | Please use the [issue tracker](https://github.com/architv/harvey/issues) to report any bugs or file feature requests. 121 | 122 | #### Developing 123 | 124 | PRs are welcome. To begin developing, do this: 125 | 126 | ```bash 127 | # make virtual env 128 | $ git clone git@github.com:architv/harvey.git 129 | $ pip install requirements.txt 130 | $ cd harvey/ 131 | $ python harvey/harvey.py mit 132 | ``` 133 | 134 | Licence 135 | ==== 136 | Open sourced under [MIT License](LICENSE) (Created by harvey) 137 | 138 | Image: [buylocalexperts.com](http://www.buylocalexperts.com/sanantonio/images/stories/buy-local-legal-expert.png) 139 | -------------------------------------------------------------------------------- /harvey/harvey.py: -------------------------------------------------------------------------------- 1 | r""" 2 | 3 | Harvey is a command line legal expert who manages license for you. 4 | 5 | Usage: 6 | harvey (ls | list) 7 | harvey --tldr 8 | harvey 9 | harvey --export 10 | harvey (-h | --help) 11 | harvey --version 12 | Options: 13 | -h --help Show this screen. 14 | --version Show version. 15 | 16 | """ 17 | 18 | 19 | import json 20 | import os 21 | import re 22 | import subprocess 23 | import sys 24 | from datetime import date 25 | 26 | import requests 27 | from colorama import Fore, Back, Style 28 | from docopt import docopt 29 | 30 | requests.packages.urllib3.disable_warnings() 31 | 32 | __version__ = '0.0.5' 33 | 34 | BASE_URL = "https://api.github.com" 35 | _HEADERS = {'Accept': 'application/vnd.github.drax-preview+json'} 36 | _LICENSES = {} 37 | _ROOT = os.path.abspath(os.path.dirname(__file__)) 38 | 39 | filename = "licenses.json" 40 | abs_file = os.path.join(_ROOT, filename) 41 | 42 | with open(abs_file, 'r') as f: 43 | _LICENSES = json.loads(f.read()) 44 | 45 | 46 | def _stripslashes(s): 47 | '''Removes trailing and leading backslashes from string''' 48 | r = re.sub(r"\\(n|r)", "\n", s) 49 | r = re.sub(r"\\", "", r) 50 | return r 51 | 52 | 53 | def _get_config_name(): 54 | '''Get git config user name''' 55 | p = subprocess.Popen('git config --get user.name', shell=True, 56 | stdout=subprocess.PIPE, stderr=subprocess.STDOUT) 57 | output = p.stdout.readlines() 58 | return _stripslashes(output[0]) 59 | 60 | 61 | def _get_licences(): 62 | """ Lists all the licenses on command line """ 63 | licenses = _LICENSES 64 | 65 | for license in licenses: 66 | print("{license_name} [{license_code}]".format( 67 | license_name=licenses[license], license_code=license)) 68 | 69 | 70 | def _get_license_description(license_code): 71 | """ Gets the body for a license based on a license code """ 72 | req = requests.get("{base_url}/licenses/{license_code}".format( 73 | base_url=BASE_URL, license_code=license_code), headers=_HEADERS) 74 | 75 | if req.status_code == requests.codes.ok: 76 | s = req.json()["body"] 77 | search_curly = re.search(r'\{(.*)\}', s) 78 | search_square = re.search(r'\[(.*)\]', s) 79 | license = "" 80 | replace_string = '{year} {name}'.format(year=date.today().year, 81 | name=_get_config_name()) 82 | 83 | if search_curly: 84 | license = re.sub(r'\{(.+)\}', replace_string, s) 85 | elif search_square: 86 | license = re.sub(r'\[(.+)\]', replace_string, s) 87 | else: 88 | license = s 89 | 90 | return license 91 | else: 92 | print(Fore.RED + 'No such license. Please check again.'), 93 | print(Style.RESET_ALL), 94 | sys.exit() 95 | 96 | 97 | def get_license_summary(license_code): 98 | """ Gets the license summary and permitted, forbidden and required 99 | behaviour """ 100 | try: 101 | abs_file = os.path.join(_ROOT, "summary.json") 102 | with open(abs_file, 'r') as f: 103 | summary_license = json.loads(f.read())[license_code] 104 | 105 | # prints summary 106 | print(Fore.YELLOW + 'SUMMARY') 107 | print(Style.RESET_ALL), 108 | print(summary_license['summary']) 109 | 110 | # prints source for summary 111 | print(Style.BRIGHT + 'Source:'), 112 | print(Style.RESET_ALL), 113 | print(Fore.BLUE + summary_license['source']) 114 | print(Style.RESET_ALL) 115 | 116 | # prints cans 117 | print(Fore.GREEN + 'CAN') 118 | print(Style.RESET_ALL), 119 | for rule in summary_license['can']: 120 | print(rule) 121 | print('') 122 | 123 | # prints cannot 124 | print(Fore.RED + 'CANNOT') 125 | print(Style.RESET_ALL), 126 | for rule in summary_license['cannot']: 127 | print(rule) 128 | print('') 129 | 130 | # prints musts 131 | print(Fore.BLUE + 'MUST') 132 | print(Style.RESET_ALL), 133 | for rule in summary_license['must']: 134 | print(rule) 135 | print('') 136 | 137 | except KeyError: 138 | print(Fore.RED + 'No such license. Please check again.'), 139 | print(Style.RESET_ALL), 140 | 141 | 142 | def save_license(license_code): 143 | """ Grab license, save to LICENSE/LICENSE.txt file """ 144 | desc = _get_license_description(license_code) 145 | fname = "LICENSE" 146 | if sys.platform == "win32": 147 | fname += ".txt" # Windows and file exts 148 | with open(os.path.join(os.getcwd(), fname), "w") as afile: 149 | afile.write(desc) 150 | 151 | 152 | def main(): 153 | ''' harvey helps you manage and add license from the command line ''' 154 | arguments = docopt(__doc__, version=__version__) 155 | 156 | if arguments['ls'] or arguments['list']: 157 | _get_licences() 158 | elif arguments['--tldr'] and arguments['']: 159 | get_license_summary(arguments[''].lower()) 160 | elif arguments['--export'] and arguments['']: 161 | save_license(arguments[''].lower()) 162 | elif arguments['']: 163 | print(_get_license_description(arguments[''].lower())) 164 | else: 165 | print(__doc__) 166 | 167 | 168 | if __name__ == '__main__': 169 | main() 170 | -------------------------------------------------------------------------------- /harvey/summary.json: -------------------------------------------------------------------------------- 1 | { 2 | "apache-2.0": { 3 | "source": "https://tldrlegal.com/l/apache2", 4 | "must": [ 5 | "include-copyright", 6 | "document-changes" 7 | ], 8 | "cannot": [ 9 | "trademark-use", 10 | "no-liability" 11 | ], 12 | "can": [ 13 | "commercial-use", 14 | "modifications", 15 | "distribution", 16 | "sublicense", 17 | "patent-grant", 18 | "private-use" 19 | ], 20 | "summary": "You can do what you like with the software, as long as you include the required notices. This permissive license contains a patent license from the contributors of the code." 21 | }, 22 | "lgpl-3.0": { 23 | "source": "https://tldrlegal.com/l/lgpl-3.0", 24 | "must": [ 25 | "include-copyright", 26 | "library-usage", 27 | "disclose-source" 28 | ], 29 | "cannot": [ 30 | "no-liability" 31 | ], 32 | "can": [ 33 | "commercial-use", 34 | "modifications", 35 | "distribution", 36 | "sublicense", 37 | "patent-grant", 38 | "private-use" 39 | ], 40 | "summary": "This license is mainly applied to libraries. You may copy, distribute and modify the software provided that modifications are described and licensed for free under LGPL. Derivatives works (including modifications or anything statically linked to the library) can only be redistributed under LGPL, but applications that use the library don't have to be." 41 | }, 42 | "gpl-2.0": { 43 | "source": "https://tldrlegal.com/l/gpl2", 44 | "must": [ 45 | "include-copyright", 46 | "document-changes", 47 | "disclose-source" 48 | ], 49 | "cannot": [ 50 | "no-liability", 51 | "no-sublicense" 52 | ], 53 | "can": [ 54 | "commercial-use", 55 | "modifications", 56 | "distribution", 57 | "patent-grant", 58 | "private-use" 59 | ], 60 | "summary": "You may copy, distribute and modify the software as long as you track changes/dates in source files. Any modifications to or software including (via compiler) GPL-licensed code must also be made available under the GPL along with build & install instructions." 61 | }, 62 | "mpl-2.0": { 63 | "source": "https://tldrlegal.com/l/mpl-2.0", 64 | "must": [ 65 | "disclose-source", 66 | "include-copyright" 67 | ], 68 | "cannot": [ 69 | "no-liability", 70 | "trademark-use" 71 | ], 72 | "can": [ 73 | "commercial-use", 74 | "modifications", 75 | "distribution", 76 | "sublicense", 77 | "patent-grant", 78 | "private-use" 79 | ], 80 | "summary": "MPL is a copyleft license that is easy to comply with. You must make the source code for any of your changes available under MPL, but you can combine the MPL software with proprietary code, as long as you keep the MPL code in a separate file. Version 2.0 is compatible with GPL version 3. You can distribute binaries under a proprietary license, as long as you make the source available under MPL." 81 | }, 82 | "gpl-3.0": { 83 | "source": "https://tldrlegal.com/l/gpl-3.0", 84 | "must": [ 85 | "include-copyright", 86 | "document-changes", 87 | "disclose-source" 88 | ], 89 | "cannot": [ 90 | "no-liability", 91 | "no-sublicense" 92 | ], 93 | "can": [ 94 | "commercial-use", 95 | "modifications", 96 | "distribution", 97 | "patent-grant", 98 | "private-use" 99 | ], 100 | "summary": "You may copy, distribute and modify the software as long as you track changes/dates in source files. Any modifications to or software including (via compiler) GPL-licensed code must also be made available under the GPL along with build & install instructions." 101 | }, 102 | "unlicense": { 103 | "source": "https://tldrlegal.com/license/unlicense", 104 | "must": [], 105 | "cannot": [ 106 | "no-liability" 107 | ], 108 | "can": [ 109 | "private-use", 110 | "commercial-use", 111 | "modifications", 112 | "distribution", 113 | "sublicense" 114 | ], 115 | "summary": "Releases code into the public domain, thereby releasing all rights you may hold to that code." 116 | }, 117 | "cc0-1.0": { 118 | "source": "https://tldrlegal.com/l/cc0-1.0", 119 | "must": [], 120 | "cannot": [ 121 | "no-liability" 122 | ], 123 | "can": [ 124 | "commercial-use", 125 | "modifications", 126 | "distribution", 127 | "private-use" 128 | ], 129 | "summary": "Releases software into the public domain, or otherwise grants permission to use it for any purpose. Disclaims patent licenses." 130 | }, 131 | "artistic-2.0": { 132 | "source": "https://tldrlegal.com/l/artistic", 133 | "must": [ 134 | "include-copyright", 135 | "document-changes" 136 | ], 137 | "cannot": [ 138 | "no-liability", 139 | "trademark-use" 140 | ], 141 | "can": [ 142 | "commercial-use", 143 | "modifications", 144 | "distribution", 145 | "sublicense", 146 | "private-use" 147 | ], 148 | "summary": "This is a license for software packages with the intent of giving the original copyright holder some measure of control over his software while still remaining open source. It is flexible and allows you to distribute or sell modified versions as long as you fulfill one of various conditions. Look at section 4 in the full text for a better explanation." 149 | }, 150 | "agpl-3.0": { 151 | "source": "https://tldrlegal.com/l/agpl3", 152 | "must": [ 153 | "include-copyright", 154 | "document-changes", 155 | "disclose-source", 156 | "network-use-disclose" 157 | ], 158 | "cannot": [ 159 | "no-liability", 160 | "no-sublicense" 161 | ], 162 | "can": [ 163 | "commercial-use", 164 | "modifications", 165 | "distribution", 166 | "patent-grant", 167 | "private-use" 168 | ], 169 | "summary": "The AGPL license differs from the other GNU licenses in that it was built for network software. You can distribute modified versions if you keep track of the changes and the date you made them. As per usual with GNU licenses, you must license derivatives under AGPL. It provides the same restrictions and freedoms as the GPLv3 but with an additional clause which makes it so that source code must be distributed along with web publication. Since web sites and services are never distributed in the traditional sense, the AGPL is the GPL of the web." 170 | }, 171 | "isc": { 172 | "source": "https://tldrlegal.com/l/isc", 173 | "must": [ 174 | "include-copyright" 175 | ], 176 | "cannot": [ 177 | "no-liability" 178 | ], 179 | "can": [ 180 | "commercial-use", 181 | "distribution", 182 | "modifications", 183 | "private-use", 184 | "sublicense" 185 | ], 186 | "summary": "A short, permissive software license. Basically, you can do whatever you want as long as you include the original copyright.\u00a0" 187 | }, 188 | "lgpl-2.1": { 189 | "source": "https://tldrlegal.com/l/lgpl2", 190 | "must": [ 191 | "include-copyright", 192 | "library-usage", 193 | "disclose-source" 194 | ], 195 | "cannot": [ 196 | "no-liability" 197 | ], 198 | "can": [ 199 | "commercial-use", 200 | "modifications", 201 | "distribution", 202 | "sublicense", 203 | "patent-grant", 204 | "private-use" 205 | ], 206 | "summary": "This license mainly applies to libraries. You may copy, distribute and modify the software provided that you state modifications and license them under LGPL-2.1. Anything statically linked to the library can only be redistributed under LGPL, but applications that use the library don't have to be. \u00a0You must allow reverse engineering of your application as necessary to debug and relink the library." 207 | }, 208 | "epl-1.0": { 209 | "source": "https://tldrlegal.com/l/epl", 210 | "must": [ 211 | "disclose-source", 212 | "include-copyright" 213 | ], 214 | "cannot": [ 215 | "no-liability" 216 | ], 217 | "can": [ 218 | "commercial-use", 219 | "distribution", 220 | "modifications", 221 | "sublicense", 222 | "patent-grant", 223 | "private-use" 224 | ], 225 | "summary": "This license, made and used by the Eclipse Foundation, is similar to GPL but allows you to link code under the license to proprietary applications. You may also license binaries under a proprietary license, as long as the source code is available under EPL." 226 | }, 227 | "bsd-3-clause": { 228 | "source": "https://tldrlegal.com/l/bsd3", 229 | "must": [ 230 | "include-copyright" 231 | ], 232 | "cannot": [ 233 | "no-liability", 234 | "trademark-use" 235 | ], 236 | "can": [ 237 | "commercial-use", 238 | "modifications", 239 | "distribution", 240 | "sublicense", 241 | "private-use" 242 | ], 243 | "summary": "The BSD 3-clause license allows you almost unlimited freedom with the software so long as you include the BSD copyright and license notice in it (found in Fulltext).\u00a0" 244 | }, 245 | "bsd-2-clause": { 246 | "source": "https://tldrlegal.com/l/freebsd", 247 | "must": [ 248 | "include-copyright" 249 | ], 250 | "cannot": [ 251 | "no-liability" 252 | ], 253 | "can": [ 254 | "commercial-use", 255 | "modifications", 256 | "distribution", 257 | "sublicense", 258 | "private-use" 259 | ], 260 | "summary": "The BSD 2-clause license allows you almost unlimited freedom with the software so long as you include the BSD copyright notice in it (found in Fulltext). Many other licenses are influenced by this one." 261 | }, 262 | "mit": { 263 | "source": "https://tldrlegal.com/l/mit", 264 | "must": [ 265 | "include-copyright" 266 | ], 267 | "cannot": [ 268 | "no-liability" 269 | ], 270 | "can": [ 271 | "commercial-use", 272 | "modifications", 273 | "distribution", 274 | "sublicense", 275 | "private-use" 276 | ], 277 | "summary": "A short, permissive software license. Basically, you can do whatever you want as long as you include the original copyright and license notice in any copy of the software/source. \u00a0There are many variations of this license in use." 278 | } 279 | } --------------------------------------------------------------------------------