Skip to content

pschlump/css-pack

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

css-pack

license

CSS Packer (CSS Uglify) in go (golang)

Example

	$ css-pack -i my_css_file.css -o my_css_file.min.css

Will pack and remove comments from the CSS file.

Options

Option Description
-i <file.css> Input file.
-o <file.min.css> Packed output file.
-d <file.out> Dependencies in the CSS file. These are url() and @import.
-D Debug flag

To build

	$ git clone https://github.com/pschlump/css-pack.git
	$ cd css-pack
	$ go get
	$ go build
	$ ./css-pack -i test2.css -o test2.min.css
	$ diff test2.ref.css test2.min.css

And a quick test

	$ ./css-pack -i test2.css -o test2.min.css
	$ diff test2.ref.css test2.min.css

TODO

  1. It has the start for a -s source map - that code is still in progress.
  2. Add in ability to include .css dependencies that are imported into a single file.
  3. Make it faster. This is mostly replace the existing CSS scanner with a faster one - lexie.

About

CSS Packer (CSS Uglify) in go

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published