TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Libsass – C implementation of a Sass compiler

117 点作者 kudu超过 11 年前

15 条评论

hcatlin超过 11 年前
Wow, didn&#x27;t expect to see this at the top of HN. Thanks kudo for promoting the project!<p>Aaron Leung and I have been working on this for a while. I&#x27;m the original creator of Sass and Aaron is a badass computer linguist. Hoping to announce some big new features around the end of the year.<p>Official site is at: <a href="http://libsass.org" rel="nofollow">http:&#x2F;&#x2F;libsass.org</a> Or, follow us on Twitter for more updates: @hcatlin &amp; @akhleung
评论 #6798604 未加载
评论 #6798897 未加载
评论 #6798712 未加载
评论 #6798612 未加载
评论 #6799553 未加载
danenania超过 11 年前
This is great as compilation in ruby really is painfully slow for anything substantial, but I wonder about the choice of an independent project vs. forking the ruby compiler and optimizing the bottlenecks with C extensions. Might that allow you to fix the most serious issues without having to worry about maintaining feature parity in a completely separate code base?<p>In any case, nice work. I look forward to trying it out in my next project.
评论 #6798693 未加载
评论 #6799315 未加载
pilif超过 11 年前
I&#x27;m periodically updating a PHP binding to libsass on my companies github account here: <a href="https://github.com/sensational/sassphp" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;sensational&#x2F;sassphp</a><p>It was my intention of keeping up with releases, but it looks like updating it periodically to git HEAD of libsass might be what&#x27;s needed. I&#x27;ll look into getting the submodule updated to a later release today.<p>That said: last summer when I started maintaining this fork of an earlier binding, I noticed that libsass (even tag RELEASE-1.0) was in a bit an early state of development: HEAD was flat-out segfaulting and RELEASE-1.0 was producing miscompilations.<p>I&#x27;ve reported a few bugs but in the end, we&#x27;ve settled back with ruby sass for the time being. The speed up is nice, but only if the library is actually producing valid output without crashing.<p>Maybe by now this is better and I should give it another go :-)<p>Also, I&#x27;m certainly no C++ programmer and thus this might be common, but their template based parser with a lot of implementation code in a header file kind of scares me (<a href="https://github.com/hcatlin/libsass/blob/master/prelexer.hpp" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;hcatlin&#x2F;libsass&#x2F;blob&#x2F;master&#x2F;prelexer.hpp</a>)
评论 #6799115 未加载
评论 #6799096 未加载
mfkp超过 11 年前
For all the Go fans out there, I built a sass watcher&#x2F;compiler using Go + libsass, I&#x27;d love to get some feedback. <a href="https://github.com/mfkp/gassy" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;mfkp&#x2F;gassy</a>
leif超过 11 年前
I&#x27;m not a web guy, but isn&#x27;t sass a CSS generator, as in something you run once before deploying anything? What&#x27;s the advantage of speed for something like this?
评论 #6798866 未加载
评论 #6798571 未加载
评论 #6798541 未加载
评论 #6798559 未加载
评论 #6798902 未加载
评论 #6798549 未加载
评论 #6798548 未加载
评论 #6798656 未加载
评论 #6798543 未加载
评论 #6798566 未加载
__david__超过 11 年前
I&#x27;ve been maintaining a Perl binding to libsass.<p>CPAN page here: <a href="http://search.cpan.org/perldoc?CSS%3A%3ASass" rel="nofollow">http:&#x2F;&#x2F;search.cpan.org&#x2F;perldoc?CSS%3A%3ASass</a><p>Github here: <a href="https://github.com/caldwell/CSS-Sass" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;caldwell&#x2F;CSS-Sass</a>
calinet6超过 11 年前
Let&#x27;s get down to brass tacks—is there a ruby gem which can use this and drop into the Rails asset pipeline to speed it up? If not, what would be the best way to get that started?<p>Edit: found this: <a href="https://github.com/hcatlin/sassruby" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;hcatlin&#x2F;sassruby</a> -- Looks like it&#x27;s not quite mature enough, but promising!
评论 #6798710 未加载
pedrocr超过 11 年前
<i>Any contribution to the project are seen as copyright assigned to Hampton Catlin, a human on the planet earth. Your contribution warrants that you have the right to assign copyright on your work. The intention here is to ensure that the project remains totally free (liberal, like).</i><p>That&#x27;s a curious setup. The license is MIT so you&#x27;re not getting the &quot;if you distribute it you have to use the same license&quot; that you get with GPL. So as long as the contributions use the same MIT license why does the author need copyright assignment? The MIT license is simple and standard enough that relicensing doesn&#x27;t seem like a likely need.
评论 #6802559 未加载
lobster_johnson超过 11 年前
Unfortunately it only implements the curly-brace SCSS syntax, not the indented SASS syntax [1] (which is weird considering it&#x27;s called Libsass, not Libscss), and there are no plans to support both syntaxes.<p>The companies I have worked for all use the indented syntax, since it meshes very well with HAML and CoffeeScript. But it looks like more people use the brace syntax (roughly 980k SCSS files on Github, vs. 85k SASS files).<p>[1] <a href="https://github.com/hcatlin/libsass/issues/16" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;hcatlin&#x2F;libsass&#x2F;issues&#x2F;16</a>
评论 #6799262 未加载
评论 #6799131 未加载
chavesn超过 11 年前
I know this is completely juvenile of me, but I can&#x27;t help but see &quot;libs ass&quot;.<p>It&#x27;s kind of like &quot;xbone&quot;. I&#x27;m sure it&#x27;s not intentional, but people will see it nonetheless.
vezzy-fnord超过 11 年前
Given that this is a C++ implementation, why the incorrect article and repo title?<p>Was it rewritten in C++ later on?<p>Otherwise, it seems interesting. I&#x27;ll look into it.
评论 #6798551 未加载
chrismorgan超过 11 年前
So, three months ago they started using Travis CI and, as far as I can tell from looking at the results (<a href="https://travis-ci.org/hcatlin/libsass/builds" rel="nofollow">https:&#x2F;&#x2F;travis-ci.org&#x2F;hcatlin&#x2F;libsass&#x2F;builds</a>), <i>not once have the tests actually passed</i>. (Builds 1 and 2 failed silently and build 8 didn&#x27;t test anything. The rest were all detected as failing.)
评论 #6799602 未加载
评论 #6803834 未加载
pjmlp超过 11 年前
It looks like C++ to me.
lightblade超过 11 年前
Do wanted to note that this does not work with Compass currently as Compass extends SASS with Ruby.
评论 #6799329 未加载
smrtinsert超过 11 年前
I really want a pure js impl.
评论 #6800163 未加载