Git Product home page Git Product logo

Comments (21)

keegnotrub avatar keegnotrub commented on September 6, 2024 2

@jschreck as mentioned above, there is some places that the plugin will automatically match where to place the accompanying css file.

Presently, if you are saving a file named style.scss the plugin will:

  1. Look to see if style.css exists in the same directory as style.scss. If so, it will use that.
  2. Look up one directory to see if we have a directory named either css, styles, stylesheets, or style. If so, it will generate style.css in that directory.

Would you be able to let me know if the above doesn't fit your use case and if so what your specific use case looks like? Thanks!

from coda-sass-plugin.

keegnotrub avatar keegnotrub commented on September 6, 2024 1

Hmm, that should work as well provided that none of the parent directories contain a matching {name}.css file. Could you check all the intermediate directories and if any contain a {name}.css file delete it and re-save?

My comment above wasn't absolutely complete in terms of the algorithm, more explicitly it looks like this:

  1. Look to see if {name}.css exists in the same directory as {name}.scss. If so, it will use that.
  2. Look up one directory to see if we have a directory named either css, styles, stylesheets, or style. If so, it will generate style.css in that directory.
  3. Repeat step 2 until we run out of parent directories
  4. If nothing was found in step 3, then just save in the same directory as {name}.scss

from coda-sass-plugin.

rfmarcelino avatar rfmarcelino commented on September 6, 2024

Yes, this would be very useful. The CSS is being generated to the same sass folder while compass compile / watch saves it to ../css

from coda-sass-plugin.

keegnotrub avatar keegnotrub commented on September 6, 2024

@rfmarcelino - There is some "intelligence" as to where it finds the accompanying css file for the scss file you are saving. Could you try this:

  1. Move (don't copy) the css file that is being generated to ../css
  2. Open the scss file make a change and save
  3. Check to see if the css file located in ../css was updated

from coda-sass-plugin.

jschreck avatar jschreck commented on September 6, 2024

@keegnotrub - I tested this and it does indeed work. Might be useful to add to the readme here.

Naturally, having a preferred output path config would still be more awesome, but I'll take it. : +1:

Thanks for responding.

from coda-sass-plugin.

rfmarcelino avatar rfmarcelino commented on September 6, 2024

Thanks @keegnotrub, that worked !
Could be useful to have this info somewhere besides here. In my case this was a make/break feature.
Thanks a lot for your great work.

from coda-sass-plugin.

createchlondon avatar createchlondon commented on September 6, 2024

One thing that doesn't seem to be working for me is there is a stylesheet located at "../stylesheets/{name}.css" but it isn't locating this automatically. Could we add a rule to automatically check the parent directories?

from coda-sass-plugin.

keegnotrub avatar keegnotrub commented on September 6, 2024

Hmm.. That should work - just to double check, could you make sure there isn't already a matching {name}.css file in your sass directory? If there is, delete that first before saving as it may be finding that before it finds your "../stylesheets" directory.

from coda-sass-plugin.

createchlondon avatar createchlondon commented on September 6, 2024

Sorry I'm using the foundation framework, the stylesheet is actually located at "../../stylesheets/{name}.css" so it's 2 directories up.

from coda-sass-plugin.

createchlondon avatar createchlondon commented on September 6, 2024

Please see this screenshot of the directory structure from Foundation - http://s9.postimg.org/bosb41gfz/Screen_Shot_2015_12_11_at_2_32_16_p_m.png.

I saved the scss and it writes it to the same folder 'config'. I tried deleting foundation.css from the stylesheets folder and resaving the scss but it does the same thing and writes foundation.css to the config directory. Not sure if I'm doing something wrong or it just isn't noticing where the file should be written to.

By the way, thanks for your quick replies! Apart from that this module works perfectly.

from coda-sass-plugin.

keegnotrub avatar keegnotrub commented on September 6, 2024

Thanks for snapshot. I don't see anything immediately so I might have to setup a test like this to see why you are getting this behavior. I may not have time immediately to do so but I'll try to look into it soon.

from coda-sass-plugin.

createchlondon avatar createchlondon commented on September 6, 2024

No problem I don't mind copy/pasting the document each time for now. For test purposes, I am working on the Foundation WordPress framework.

from coda-sass-plugin.

keegnotrub avatar keegnotrub commented on September 6, 2024

Thanks for this again, it looks like I found the issue. I'll publish an update, in the meantime - I believe this should work for you if you rename your "stylesheets" directory to "css", then make sure to delete any "foundation.css" files and try again.

from coda-sass-plugin.

createchlondon avatar createchlondon commented on September 6, 2024

Okay great thank you, please let me know when there is a fix available and how I can upgrade. Many thanks.

On 11 Dec 2015, at 14:58, Ryan Krug [email protected] wrote:

Thanks for this again, it looks like I found the issue. I'll publish an update, in the meantime - I believe this should work for you if you rename your "stylesheets" directory to "css", then make sure to delete any "foundation.css" files and try again.


Reply to this email directly or view it on GitHub.

from coda-sass-plugin.

keegnotrub avatar keegnotrub commented on September 6, 2024

Fix should be included in this release:

https://github.com/keegnotrub/coda-sass-plugin/releases/tag/v3.1.2

from coda-sass-plugin.

createchlondon avatar createchlondon commented on September 6, 2024

Great thank you!

On 14 Dec 2015, at 1:28 pm, Ryan Krug [email protected] wrote:

Fix should be included in this release:

https://github.com/keegnotrub/coda-sass-plugin/releases/tag/v3.1.2 https://github.com/keegnotrub/coda-sass-plugin/releases/tag/v3.1.2

Reply to this email directly or view it on GitHub #22 (comment).

from coda-sass-plugin.

heathflohre avatar heathflohre commented on September 6, 2024

Sorry to open this back up, but I just started using this plugin and it only recognizes a folder named 'css' one directory up. If it's names styles, stylesheets, etc. or if it's more than one directory up, it defaults to compiling in the same directory. Using Coda 2.5.16 and the most recent plugin.

from coda-sass-plugin.

keegnotrub avatar keegnotrub commented on September 6, 2024

Thanks @heathflohre - Can you double check that you are running the most recent plugin from the release page on Github:

https://github.com/keegnotrub/coda-sass-plugin/releases/tag/v3.1.2

I believe Panic is still using v3.1.1 which didn't include this fix. I've been meaning to submit the fix to Panic as well, but haven't yet.

from coda-sass-plugin.

heathflohre avatar heathflohre commented on September 6, 2024

It was version 3.1.1, but it's still occuring with 3.1.2.

from coda-sass-plugin.

heathflohre avatar heathflohre commented on September 6, 2024

After testing, it is now recognizing directories with the other names. I was hoping it would look inside folders one level up. So, if 'scss' and 'build' folders are at the same level, it would save the compiled file in 'build/css'.

from coda-sass-plugin.

reddenial avatar reddenial commented on September 6, 2024

Hello,
I'm working with Coda 2.5.16 and I installed the plugin version 3.1.2

I created a folder named "site/customer/scss" with a file inside name "screen.scss"
The plugin works good at this point because it creates a folder "site/customer/css" and "screen.css".

But after I created a folder "admin" inside the "scss" one with the file "admin.scss" ( path is : "site/customer/scss/admin/admin.scss") , the output "admin.css" goes to the parent :

"site/customer/css/admin.css" instead of "site/customer/css/admin/admin.css"

It is possible to change this?

Here's the screenshot :
capture d ecran 2016-06-08 a 12 10 57

(others files are not created with SASS)

from coda-sass-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.