node.js - How do I edit a Meteor package from Atmosphere that's not on GitHub? -


i have twitter functionality i'm working on , want use "application-only authentication" needs twitter application credentials perform gets in app (e.g. random tweet searches based on user inputted tags, etc. - no actual user posting.)

twitter supports of twitter packages on atmosphere , npm not. force pass both application credentials , oauth tokens, if don't, requests come invalid. popular meteor twitter api package called mrt:twit wraps npm package ttezel/twit implements application-only authentication correctly, wrapper package meteor mrt:twit forces use full authentication requiring user's oauth tokens don't want or need use. i'd edit mrt:twit follow ttezel/twit's interface.

however, mrt:twit package not on github. how figure out lives and/or if can access locally , modify and/or find repository online lives? atmosphere doesn't offer providing no links package downloading?

link mrt:twit: https://atmospherejs.com/mrt/twit

link ttezel/twit: https://github.com/ttezel/twit

edit: i'm using meteor 1.1.0.2. able find mrt:twit locally. it's at:

.../.meteor/local/build/programs/server/packages/

after investigating, it's not mrt:twit doesn't "implement" ttezel/twit's interface correctly, it's mrt:twit using/requiring old version of ttezel/twit, version 1.1.9 instead of current 2.1.0. old version of ttezel/twit doesn't support "application-only" authorization - can see in code. hence above original issue. ttezel/twit downloads following folder:

.../.meteor/local/build/programs/server/npm/mrt_twit/node_modules/twit

inside above folder see full .git package ttezel/twit it's version 1.1.9. assume replace folder latest 2.1.0 version of ttezel/twit don't think you're supposed have mess inside of node_modules folder right? shouldn't there config file somewhere edit?

for life of me can't find mrt:twit declaring use version 1.1.9. in code calls npm.require('twit'). there's no config file can find sets version 1.1.9. thing found file @ second path above sitting next twit folder called .node_version , has in v0.10.20 version of node use assume. wouldn't "force" whatever package versions out @ time it? if so, that's setting ttezel/twit use 1.1.9.

my original post question still exists though, can find mrt:twit on server can fork it/edit , not have edit code locally?

i emailed creators of atmosphere (percolatestudio.com) , tom helpful , pointed me mrt:twit lives on github. it's on old 1.0 atmosphere:

https://old-atmosphere.meteor.com/package/twit

and page points actual github location is:

https://github.com/subhog/meteor-twit

so above link current mrt:twit package downloads meteor app if add app (as of writing). once found see in package.js file declares npm.depends({twit: "1.1.9"}). on side note: nice if current version of atmosphere pointed github location of older/legacy packages how new packages.

so able fork , update package use version 2.1.0 of ttezel/twit. made pull request mrt:twit author updates - number 1 twitter api package meteor 1,200 downloads. seemed better update publish own version.

until then, made local package following below link , working great - including application-only authentication. comments - helpful. i'm still pretty new @ meteor , how packaging system works.

http://www.webtempest.com/meteor-js-packages-tutorial

if want access updated package made it's @ below link it's not published meteor package - you'll have download , use locally:

https://github.com/evolross/meteor-twit


Comments

Popular posts from this blog

qt - Using float or double for own QML classes -

Create Outlook appointment via C# .Net -

ios - Swift Array Resetting Itself -