https://github.com/zicht/color-name
Library - Convert hex color values
https://github.com/zicht/color-name
Last synced: 9 months ago
JSON representation
Library - Convert hex color values
- Host: GitHub
- URL: https://github.com/zicht/color-name
- Owner: zicht
- License: mit
- Created: 2017-09-15T14:30:40.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2024-06-19T00:35:43.000Z (almost 2 years ago)
- Last Synced: 2025-01-23T14:56:03.444Z (over 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 27.3 KB
- Stars: 1
- Watchers: 6
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Color name
Get the name of a hex color value.
Uses the website [Color name & hue](http://www.color-blindness.com/color-name-hue/).
# Requirements
* node >= 8
# Installation
```bash
git clone git@github.com:zicht/color-name.git
cd color-name
npm install
```
# Usage
The usage requires a hexadecimal argument.
Both uppercase and lowercase letters (if present) are allowed:
```bash
local/path/to/this/repository/bin/color-name fd3aaa
// output: red--wild-strawberry
local/path/to/this/repository/bin/color-name AB12FF
// output: violet--electric-purple
```
## Alias
It is recommended to create an alias, for example in your `~/.bash_aliases`. Afterwards, you can call it more easily from your terminal instead of typing out the full path.
Example: if you installed this repository in `~/code/zicht/`, then an alias command called `zcolor` would be:
```bash
alias zcolor='~/code/zicht/color-name/bin/color-name $1'
```
Executing the command in the terminal will look like this:
```bash
zcolor 461154
// output: violet--persian-indigo
```
# Maintainers
* Virginia Meijer