Comments (7)
Alright, thanks for the heads up. What is the process for sending updated versions?
from tinycolor.
You fork the cdnjs-repo, insert the files (minimized and possibly with map-file, you can just take the command I used, shown in the pull request) and update the package.json (trivial, just update the version number). Then you open a pull request.
(or you message me and I can do that if you mind the hassle.)
from tinycolor.
The code in cdnjs isn't updated btw
from tinycolor.
@yairEO Thanks, I just opend a pull request
from tinycolor.
@HoffmannP from that issue (cdnjs/cdnjs#3416) it looks like you are using
uglifyjs tinycolor.js --source-map tinycolor.min.map --mangle -o tinycolor.min.js
and tinycolor.js was downloaded from the github repository
Not that it is so hard to run that, but I do have uglify set up with grunt (https://github.com/bgrins/TinyColor/blob/master/Gruntfile.js#L12). The options aren't quite the same, but we should definitely update them so that generating files for a cdnjs compatible PR is as easy as running a git checkout TAG
grunt build
(or maybe we could add a grunt uglify
that doesn't affect the doc files).
from tinycolor.
for me it is always
git fetch upstream
git rebase mater/upstream
cd ajax/lib/tinycolor
mkdir $newVersion
cd $newVersion
wget https://raw.githubusercontent.com/bgrins/TinyColor/master/tinycolor.js
uglifyjs tinycolor.js --source-map tinycolor.min.map --mangle -o tinycolor.min.js
rm tinycolor.js
cd ..
# manually update version number in package.json to $newVersion
# could probably be automated using i.e. sed
git add $newVersion
git add package.json
git -m "Update tinycolor $newVersion"
git push
# manually open PR
There are a few steps that should/could be automated, the uglify
process is not the problem, especially as I usually don't fetch the hole tinycolor-rep
from tinycolor.
The problem is that if you wget https://raw.githubusercontent.com/bgrins/TinyColor/master/tinycolor.js
, this may be different from the tagged version of that lib (which could lead to all kinds of inconsistencies). What I would suggest is something like this (this may not be verbatim commands, but pretty close to the idea):
For TinyColor
git fetch upstream
git rebase mater/upstream
git checkout 0.11.2
uglifyjs tinycolor.js --source-map tinycolor.min.map --mangle -o tinycolor.min.js
git checkout master
For cdn
git fetch upstream
git rebase mater/upstream
cd ajax/lib/tinycolor
mkdir 0.11.2
cd 0.11.2
cp /path/to/tinycolor/dist/tinycolor.min.js . # Copies in based on actual tagged release this way
cp /path/to/tinycolor/dist/tinycolor.min.map .
cd ..
git add 0.11.2
cp /path/to/tinycolor/package.json .
git -m "Update tinycolor $newVersion"
git push
# manually open PR
There are a few steps that should/could be automated, the uglify process is not the problem, especially as I usually don't fetch the hole tinycolor-rep
Still, if we had a grunt package
command that made a folder called dist/0.11.2
and copied in the min.js
and min.map
files, then all you would have to do is copy that folder + the current package.json file into the cdnjs repo (which would get this down to many fewer steps)
from tinycolor.
Related Issues (20)
- Details lost when lightening or brightening an image
- Monochrome is only working in in darker range.
- Trying to get in touch regarding a security issue
- In built way to automatically Darken or Lighten by amount depending on the color luminance
- Is toFloatString() implemented?
- React 18 types mismatch
- Feature: include alpha in Hex HOT 2
- Is there a way to reverse a colour, like a negative image?
- Support for LCH?
- Octal literal in strict mode
- tinycolor.mix(color1, color2, amount = 50) not working in React native HOT 1
- Doesn't work with calc HOT 1
- tinycolor is not a function HOT 39
- remove `engines` field from package.json
- Task: Publish 1.6.0 to npm
- Remove tinycolor.js and dist/tinycolor-min.js once we confirm they aren't used HOT 1
- Include a Changelog HOT 4
- asset files includes ES6 syntax HOT 2
- Task: Publish 1.6.1
- [Question] Overlay Colors
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tinycolor.