Errors running Grunt and Sass - gruntjs

I've been trying to get Sass up and running with Bootstrap. I've followed the tutorial, going so far as to install exact versions of the dependencies listed rather than the default/latest versions. I've done this from scratch at least three times. I've uninstalled and reinstalled different versions of Sass and Compass (mainly according to Sass --compass --watch Error: Cannot load compass), as well as older versions of Ruby (I just installed 2.3.3, down from the latest release).
But whenever I get to running the grunt sass command, something goes wrong. I've gotten errors about not being able to load Compass. If I search and rectify that, I'll go through an error or two more (not on hand sorry, I've closed everything out), but keep ending up on:
C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/compass-core-1.1.0.alpha.3/lib/compass/core/caniuse.rb:72: warning: circular argument reference - browsers
NoMethodError:  
Use --trace for backtrace.
Warning: Exited with error code 1 Use --force to continue.
I've looked up this error, and I've tried doing the bundle update listed here, but end up right back where I started with the same problems (since now there are updated versions of dependencies that apparently don't play well together, and compass things don't work again).
I know how to use Sass, I just can't practice since I can't get it running. I'm newer to coding, and I don't know Ruby at all, so I'm stuck now that my search-fu has failed me. My machine is running Windows 10. I am specifically looking to set up Sass to run with Bootstrap 4 (yes, I know it's in alpha, it's what I'm required to use for work) and there doesn't seem to be any good documentation out there about how to actually get it running properly.

Related

FirebaseFirestoreSwift - No Such Module w/ SPM

Xcode 13.1 on a Mac M1. Moving from Cocoapods to SPM. Add the https://github.com/firebase/firebase-ios-sdk.git dependency. One of my classes uses the #DocumentID tag which uses FirebaseFirestoreSwift. However, even though it is imported in the class I get the error No such module FirebaseFirestoreSwift.
It clearly sees this module as when I start typing the import statement, it comes up. However, it won't compile with the error listed above. I tried to remove and reinstall the dependency, but same result. Numerous clean build folders and exiting and coming back into Xcode. No joy.
What can I do here?
You have to add the FirebaseFirestoreSwift-beta package. See how here

TypeScript compiler failing on a mac

Typescript compilation task works fine on linux machines but on a mac fails with the following not particularly useful error message and what looks like a binary dump.
$ grunt
Running "ts:build" (ts) task
Compiling...
Fast compile will not work when --out is specified. Ignoring fast compilation
Using tsc v1.4.1
������������=��AF���=����
>> Error: tsc return code: 3
Warning: Task "ts:build" failed. Use --force to continue.
Aborted due to warnings.
Im using nvm with node v0.11.4 and rvm with ruby v2.2.0.
Any ideas how to fix this, or even debug?
As the question includes debugging, here are some pointers which might help determine where the problem is.
Try compiling from the command line with tsc alone (no grunt), in case the problem is with grunt or the ts:build task (looks like grunt-ts).
Maybe one of your source files is causing the tools to crash (perhaps they can't cope with a file's encoding?). If a single, simple file will compile, then try removing subsets of your source from the build. If some of those files are causing the crash (whether valid TypeScript or not) you may be able to find a temporary workaround.
Try compiling with different versions of tsc. If you need 1.4.1 features you could try using the latest from https://github.com/Microsoft/TypeScript (see here for how to do this with grunt-ts).
The problem was with a malfunctioning node installation. I upgraded to node 0.12 which fixed the problem.
Just to check the problem wasn't node 0.11.4 specific I removed all previous versions of node and reinstalled 0.11.4 and the error no longer occurs.
I took these steps after removing all node modules, clearing the cache and reinstalling with no luck. I also tried using multiple typescript compiler versions.

building brackets was "Done, without errors" in Debian Wheezy, but

i was trying to build "brackets sprint 40" from source code (by following #jasonsanjose instructions look #4816 and the official wiki's page here) in my 32bit Wheezy, Using CEF3 (Verion 3.1547.1406_linux32_release with glibc 2.13) and everything was OK .
when i ran grunt build and grunt installer the output was: Running "build" task
Running "build-linux" task
Done, without errors.
and when i installed .deb package and executed it in the terminal , this error has been thrown:brackets: libcef_dll/wrapper/libcef_dll_wrapper.cc:120: int CefExecuteProcess(const CefMainArgs&, CefRefPtr): Assertion `false' failed.
Aborted
I did rebuild it many times, but the problem persist.
And this is where i stopped, i don't know where the problem lies.
some help will be appreciated, thank you in advance.
There's a duplicate of this question with longer discussion posted here - https://github.com/adobe/brackets/issues/8170.
Note: This problem shouldn't affect a "vanilla" brackets-shell build on Linux -- it's specific to a hack some people have developed to support an older version of Debian than Brackets officially supports. This requires swapping in a newer version of the CEF library, which is not always easy to do since they are not usually backwards-compatible.

chunky_png NoMethodError

I'm trying to create a sprite with compass, but I keep getting this error:
NoMethodError on line ["225"] of /Library/Ruby/Gems/2.0.0/gems/chunky_png-1.2.7/lib/chunky_png/canvas/png_encoding.rb: undefined method `downto' for 150.25:Float
I have tried everything including using previous version of chunky_png and reinstalling compass and sass.
Would love to know how to fix this.
Thanks
I found the solution. I just had to update all of my ruby gems and then restart my computer. I have had no problems since.

LESS CSS on Windows

Trying to set up LESS for CSS on my Windows box, I've installed ruby and rubygems and followed the instructions exactly.
I have put teststyle.less in C:\.
When I type
lessc teststyle.less
to compile it into a .css file, I get an error:
The filename, directory name, or volume label syntax is incorrect.
Out of those familiar with LESS, do any of you have a solution to my problem?
Did I mess up the install?
If you don't want to use GUI to compile LESS on Windows, there is a clean way to get lessc command on Windows command line. It only requires you to install node.js, which is required by original lessc anyway.
So, install node.js (http://nodejs.org/) and install "less" module for node.js. The latter provides lessc executable (lessc.cmd on Windows) as well, so you should only make sure it gets under your PATH in Windows.
If you don't have node.js yet, here are step-by-step instructions:
Install node.js (http://nodejs.org/)
In new command-line, go to node.js installation directory (where node.exe is located), and execute > npm install less (make sure you do so from node.js installation directory only)
Latter downloads less module for node.js, as well as lessc.cmd to node_modules/.bin/ directory. Add this directory to PATH
Now, in new command line you may enjoy the use of lessc as usual
Source: http://pragmatictim.blogspot.fr/2012/08/developing-with-less-on-windows-getting.html
You should look at http://www.dotlesscss.org/, less ported to C# and specifically designed for .NET. You can use either a handler or compile.
Been using it for about six months, it's great.
Oops...saw windows and assumed dot net, perhaps that's not your environment. If not, never mind...
Edit:
lessc does work on Windows now. See the Github page about commandline LESS tools for installation and usage instructions. The Github page with a list of LESS GUI tools might also be interesting.
Original answer:
The lessc command line tool for less.js doesn't work on Windows. If you want command line compiling of your LESS files you should check out this post.
Also be sure to check out WinLess. WinLess is a compiler (with GUI) for LESS. WinLess can watch your LESS files, and automatically compile them when they have changed.
If you are using Visual Studio for your projects you should also check out the BuildEventScript of winless.org.
Be sure to check which compiler is being used when you are using different programs to compile your LESS code. If you are using programs which use different compilers you should watch out for interoperability issues (LESS code working correctly with one compiler, but not with another).
FYI, I found this Windows command line tool to compile LESS into CSS useful. It uses less.js to do the compilation. The command syntax is not very graceful, but it works well.
https://github.com/duncansmart/less.js-windows
I just started using Crunch to compile Bootstrap and its pretty awesome. Its built on Adobe Air, which you will have to install if you don't already have it.
I think I found the problem. In my first installation I installed to C:\Program Files\Ruby
so I uninstalled and tried the default 'C:\Ruby' install path. Seems to fix the problem and it now works correctly. Thanks.
I have a recompiled version of DotlessCss that can accept less code from standard input and output the css code to the standard output. I have attached it at the following link LESS CSS Compiler for Windows
Only this https://github.com/leafo/lessphp PHP compiler didn't crashed with my crazy project structure with CSS imports in LESS, etc.
Very simple shell command for compiling LESS to CSS:
plessc input.less > output.css
You can use Prepros App for windows. It can compile less, sass, jade, stylus, markdown, coffeescript and haml with live browser refresh.

Resources