bdkjones / CodeKit2

CodeKit 2 Beta
97 stars 4 forks source link

Existing Compass Project #557

Closed theskillwithin closed 9 years ago

theskillwithin commented 9 years ago

Hello,

I don't use compass unless I am forced to. So when I inherit an existing compass project I would love to just load it up into codekit and it knows what it is. For example Magento ships with compass right out of the box so I can't use it with Codekit because there is only support for making a 'new' compass project. Please please make this easier for us non-compass people to use this with codekit, I know a ton of Magento developers people who would buy codekit if just this feature was added.

Thank you for your time, Austin

bdkjones commented 9 years ago

CodeKit looks for the presence of a config.rb file in the default Compass locations. If one is found, the project is recognized as a Compass project.

On 11 May 2015, at 10:38, Austin Peterson notifications@github.com wrote:

Hello,

I don't use compass unless I am forced to. So when I inherit an existing compass project I would love to just load it up into codekit and it knows what it is. For example Magento ships with compass right out of the box so I can't use it with Codekit because there is only support for making a 'new' compass project. Please please make this easier for us non-compass people to use this with codekit, I know a ton of Magento developers people who would buy codekit if just this feature was added.

Thank you for your time, Austin

— Reply to this email directly or view it on GitHub https://github.com/bdkjones/CodeKit/issues/557.

theskillwithin commented 9 years ago

Thank you for the quick response. Allow me to try this today ill report back if it works for me.

in Magento 1.9 I see config.rb here is located in: skin/frontend/rwd/default/scss

however the root dir of the codekit project would have to be atleast skin/frontend/rwd/default because the css file compiles to skin/frontend/rwd/default/css also the js is stored in skin/frontend/rwd/default/js

here is what is inside the config.rb

# note: this should never truly be refernced since we are using relative assets
http_path = "/skin/frontend/rwd/default/"
css_dir = "../css"
sass_dir = "../scss"
images_dir = "../images"
javascripts_dir = "../js"
relative_assets = true

output_style = :expanded
environment = :production
bdkjones commented 9 years ago

That's not one of the default locations for a compass config file. It should be located in the "default" folder and the asset paths in the file should be adjusted accordingly.

Sent from my iPhone

On May 11, 2015, at 11:26, Austin Peterson notifications@github.com wrote:

Thank you for the quick response. Allow me to try this today ill report back if it works for me.

in Magento 1.9 I see config.rb here is located in: skin/frontend/rwd/default/scss

however the root dir of the codekit project would have to be atleast skin/frontend/rwd/default because the css file compiles to skin/frontend/rwd/default/css also the js is stored in skin/frontend/rwd/default/js

here is what is inside the config.rb

note: this should never truly be refernced since we are using relative assets

http_path = "/skin/frontend/rwd/default/" css_dir = "../css" sass_dir = "../scss" images_dir = "../images" javascripts_dir = "../js" relative_assets = true

output_style = :expanded environment = :production — Reply to this email directly or view it on GitHub.

theskillwithin commented 9 years ago

Here is what I did.

1) make codekit use the root of your magento install.

2) configure your config.rb and place this also in your root install

here is my config.rb require "compass/import-once/activate"

http_path = "/"
css_dir = "skin/frontend/austin/default/css"
sass_dir = "skin/frontend/austin/default/scss"
images_dir = "skin/frontend/austin/default/images"
javascripts_dir = "skin/frontend/austin/default/js"

add_import_path "skin/frontend/rwd/default/scss"

output_style = :expanded
color_output = false
environment = :development

takes a long time to compile, libsass doesn't work on compass projects =[

maybe they can look into doing multi-threaded sass compile for compass projects.

theskillwithin commented 9 years ago

I'm going to see If I can't figure out how to implement this to make it faster.

https://github.com/yoheiMune/grunt-compass-multiple

bdkjones commented 9 years ago

That won't help you. Compass is written in Ruby. Ruby is slow. That's the bottom line. CodeKit already compiles on multiple threads. Ditch compass and use Libsass. It will change your life.

Sent from my iPhone

On May 11, 2015, at 13:14, Austin Peterson notifications@github.com wrote:

I'm going to see If I can't figure out how to implement this to make it faster.

https://github.com/yoheiMune/grunt-compass-multiple

— Reply to this email directly or view it on GitHub.

theskillwithin commented 9 years ago

If i can get magento compass project converted over to bourbon it will be win win win for me.

Then I could put those starter files on github.

I am starting to research how I can do this https://moovwebconfluence.atlassian.net/wiki/display/TS/Converting+Compass+based+projects+to+LibSass+and+Spracker