So I am very new to Meteor, and I was sifting through some example apps and open source projects when I came across this simple chat application:
(https://github.com/BenderV/simplechat)
I wanted to download the project, run it on my local server, and mess around with the code to learn more about what does what, and how to use the Meteor framework. I simply downloaded the .zip file from github and tried to run it (using the meteor in my terminal. However I got the following error when I ran the application locally in my browser:
Your app is crashing. Here's the latest log.
=> Errors prevented startup:
While building the application:
error: no such package: 'accounts-guest'
error: no such package: 'user-status'
error: no such package: 'accounts-testing'
error: no such package: 'fontawesome4'
error: no such package: 'iron-router'
error: no such package: 'bootstrap-3'
error: no such package: 'fast-render'
error: no such package: 'jquery-titlealert'
error: no such package: 'related'
=> Your application has errors. Waiting for file change.
I can (obviously) infer from the nature of the log that the error that I am experiencing is because I don't have the correct packages installed (the one that are listed, obviously).
So keeping this in mind, I researched how to add packages to meteor (using instructions I found on Atmosphere JS pages of the respective packages). However, when I entered the command that was provided by Atmosphere into my terminal (for example for, 'accounts-guest' package I entered: meteor add artwells:accounts-guest). Unfortunately doing this did not work, and I was given something like the following error in the terminal: artwells:accounts-guest: no such package
I have no idea what to do, the packages will not install so I can not try this code. I come from experience with Rails, and in Rails if you needed to install "gems" (pretty much the same thing as packages in Meteor) you could just enter bundle install into the terminal to download and install undefined packages. Is there something like this in Meteor? I have heard of something called Meteorite, but am unsure what it is and how to use it.
Anyways I really would appreciate any help in getting me past this minor roadblock on my way to learning Meteor!
Thank you
That's an older project which use the old packaging system 'meteorite' = 'mrt' on the command line.
I suggest you try a newer example, Meteor ships with a few. Once you have Meteor installed you can create an example app by typing one of the following commands :
meteor create --example leaderboard
meteor create --example todos
meteor create --example localmarket
And yes, there is a very similar mechanism to the gems commands you are accustomed to. Simply running a project 'meteor' should download its dependencies. Also you can run 'meteor update' if you want to update to the latest versions for your project.
Last August there was a major update to the meteor package management system, you can read more about it here : https://www.meteor.com/blog/2014/08/26/meteor-090-new-packaging-system
So, for any examples you'd like to check out, try and get a recent one, from meteor 1.0. In newer versions of meteor those instructions on Atmosphere should work out fine for you.
You can see what version of meteor a project is running by looking at this file ".meteor/release" inside a meteor project :
https://github.com/BenderV/simplechat/blob/master/.meteor/release
so you can see that one is old.
good luck!
Related
I will preface by saying I am a complete beginner at coding, and I signed up for the free trial of Pluralsight. I have spent the last four hours trying to get the very first project set up, as I have a mac and very few of the commands recommended by Pluralsight work on this computer. The project, cloned from git, is called web-dev-starter. Currently, I am trying to connect the Node packages needed for the project using the command
web-dev-starter> npm install
This returns
zsh: command not found: web-dev-starter
I have tried a lot of things and nothing works. Many thanks to whoever can help, I really want to learn to code and am considering buying a windows computer because trying to learn on a mac has been a nightmare! Thanks!
web-dev-starter> means the current directory from the file that you just clone. and after you are in that directory you just need to do npm install
I had to submit my nodejs application (written on JS and built with express generator) on the university network.
As my supervisor tried to run the application it did not render on chrome. Instead it did not build the css. The versioning of node are correct so no version Problem.
Please help!! :)
Is there a ReadMe file, with step by step instructions? Might sound flippant but since I started to document stuff like, "git clone xxxxxx, cd xxxxxx, npm install, npm run dev" the number of issues i get from new team members has dropped.
When I run both meteor add for both meteoric:ionic-sass and meteoric:ionicons.-sass, it shows the error below.
=> Errors while adding packages:
While checking for stevezhu:sass#1.3.7:
error: No compatible binary build found for this package. Contact the
package author and ask them to publish it for your platform.
I use a windows machine by the way..is that the problem? I have also posted on the Github page but I think it is not maintained or something.
I was having this issue with a different package while trying to work on a Windows machine. I ended up calling meteor update while in the directory for the meteor project I was working on and that fixed it.
I am trying to get up and running with Meteor and seeing what it can offer, while I like it overall, it seems it's a very very rigid system.
I set up a small testing setup using Velocity, it opens a small overlay window on the side which has a class of "velocityOverlay". The overlay is really small and makes error stack traces wrap. All I wanted to do was to edit the css of the "velocityOverlay" and increase the width.
I somehow (after wasting time) managed to find that Meteor is actually putting all the packages in my user directory by default, once I found that, I found the needed css file...
velocity_html-reporter/.0.5.1.aykpxq++os+web.browser+web.cordova/web.browser/packages/velocity_html-reporter/lib/client-report.less.css
And I did a small edit to the width, next thing you know the meteor app crashes when trying to launch using the "meteor" command throwing a "Error: couldn't read entire resource" error. I can't even edit the bootstrap.css file I installed using "ian_bootstrap-3".
Further more, I can't find any way to install packages locally just for my particular project, what if I wanted to modify a package only for my particular project? this is very easy to do in vanilla Node.js, you simply don't use the "-g" when using "npm install".
To add to that, within my project root, there is another ".meteor/local/build/web.browser" folder with most of the global package files replicated again. When does Meteor use which? This is very confusing.
You can run a package locally very easily.
Download it from Github (for example) and put it in the packages/ directory of your application like this /packages/package_name.
Then add it to your application with the same meteor add package_name command as usual.
Meteor will automatically look in the local folder before anywhere else and compile the package with the rest of your code.
This allows you to do any modification you want on the package and test it locally before publishing it to the registry.
Also, folders located in .meteor/local/* are used for building purpose only and are generated automatically by Meteor. So it is not the best place to edit the files!
This worked for me https://atmospherejs.com/i/publishing. mrt link-package didn't work for me, might just be outdated code.
Steps:
Download (or clone) package from GitHub to local dir
Stop meteor if running
2.1. Make sure you have a packages folder: mkdir packages
Locally link your package:
3.1 If you have mrt installed: Run mrt link-package /path/to/package in a project dir
3.2 If you don't have mrt: ln -s /path/to/package packages/package
Then run meteor add developer:package-name, do not forget to change package name
Run meteor in a project dir
From now any changes in developer:package-name package folder will cause rebuilding of project app
Download the package and place it in new package directory in your project root.
open the package.js inside the downloaded package and remove the author's name in the property "name:"
e.g: - name:'dburles:google-maps' to name:'google-maps'
then run
meteor add google-maps
I have installed Meteorite on my mac, and am trying to run the test program provided as a mysql project. When I use the command 'mrt', I get:
Stand back while Meteorite does its thing
Done installing smart packages
Ok, everything's ready. Here comes Meteor!
[[[[[ /Users/lfrey/Desktop/Thesis/test-meteor-sql ]]]]]
=> Errors prevented startup:
While building the application:
node_modules/meteor/app/lib/unsupported.html:1: Can't set DOCTYPE here. (Meteor sets for you)
node_modules/meteor/app/meteor/meteor.js:1:15: Unexpected token ILLEGAL
=> Your application has errors. Waiting for file change.
I have tried re-installing nom, meteor, meteorite, and mysql in various combinations and have not been able to eliminate the error. If I remove the command, then I get an error about invalid HTML syntax.
Your app might not be created properly. You have a node_modules directory in your application which you might have added with npm install.
Meteor does not install modules with npm install manually, it doesn't work because it parses files in the node_moules directory as part of your meteor app (in the wrong way - not as an npm module).
You have to make sure the package you use uses Npm.depends in your package's package.js. The standard Meteor-SQL package already does this for you so you don't have to worry about it.
Which SQL package did you use? As far as I can see none of them install anything with npm install nor do they have instructions to.
The simple fix to get your app working is to remove the modules you installed by deleting the node_modules directory in your app.