Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sungwoncho/license-up
Update outdated license files from your command line
https://github.com/sungwoncho/license-up
Last synced: 3 months ago
JSON representation
Update outdated license files from your command line
- Host: GitHub
- URL: https://github.com/sungwoncho/license-up
- Owner: sungwoncho
- License: mit
- Created: 2016-01-10T00:25:20.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2016-01-23T04:56:30.000Z (almost 9 years ago)
- Last Synced: 2024-10-09T09:35:42.774Z (3 months ago)
- Language: JavaScript
- Homepage:
- Size: 23.4 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# license-up
[![Build Status](https://travis-ci.org/sungwoncho/license-up.svg?branch=master)](https://travis-ci.org/sungwoncho/license-up)
Update outdated license files for your projects from command line.
![](https://cldup.com/hYgM2ktBIP.gif)
## Installation
npm install -g license-up
## Usage
In your command line:
license-up --token [INSERT_YOUR_PERSONAL_ACCESS_TOKEN]
You can easily obtain a personal access token in your settings. Read
[this](https://github.com/blog/1509-personal-api-tokens) for more info.## Why
Every year, your projects' licenses become obsolete.
On January 1, 2016, the following license file is out-of-date:
```md
Copyright (c) 2015 Sung Won ChoPermission is hereby granted, free of charge, to any person
...
```It should be updated to:
```md
Copyright (c) 2015-2016 Sung Won ChoPermission is hereby granted, free of charge, to any person
...
```Such a process becomes a hassle if you maintain multiple projects.
license-up solves that problem by automating the process using your
command line.## How it works
* It goes through all your owned repos one by one, and looks for an outdated
license file.* It *always* asks you for a confirmation before updating the license file.
e.g.
```
######### Repo: your-project #########
The license is out-of-date
Let's update Copyright (c) 2012 to Copyright (c) 2012-2016
[?] update the license [y/N]
```* If it detects a single year that is outdated, it concatenates a hyphen
followed by the current year.e.g.
`Copyright (c) 2012` becomes `Copyright (c) 2012-2016`
* If it detects a range of years of which the last part is outdated, it updates
the last part.e.g.
`Copyright (c) 2012-2015` becomes `Copyright (c) 2012-2016`
`Copyright (c) 2012 - 2015` becomes `Copyright (c) 2012 - 2016`
`Copyright (c) 2012 ~ 2015` becomes `Copyright (c) 2012 ~ 2016`## Supported license formats
license-up was tested on [MIT license](https://opensource.org/licenses/MIT). It
might not work correctly with other types of licenses. Use with care.## License
MIT