#2037 New Public (and private) fantom repo (fanr)

tcolar Wed 26 Sep 2012

I made a public + private Fantom repo :

http://repo.status302.com/

Few weeks ago I was playing with node.js, that didn't hold a candle to Fantom of course :)

But I was quite impressed by their packaging tool and repo. Even if it's a fairly new ecosystem, they already have thousands of easily installable modules in their NPM repo (similar to ruby gems but better).

Fan has had fanr for a while now and it's quite powerful, but as of now there was still no public repo for it. I think a public repo is important, it helps showcasing that the language is widely used and helps other easily find and install existing Fantom software, that makes it easy to get started too.

So anyway, the repo is a standard fanr compliant repository, but it also provides a web frontend for easy browsing/searching of pods.

Another feature is that you can also create a login/password and then on top of being able to publish to the public repo, you also get your own private repo. That can be used for software that is not yet ready for the public repo or for your own "proprietary" software.

Anyway I hope you find it helpful and whoever has made Fantom pods is VERY welcome to publish them there. I know there are quite a few out there, but they are a bit all over the place, bitbucket, github and so on.

I've used the following pods to build this repo: Draft, FantoMongo, Fanlink, Mustache, so thanks to the authors of those !

Oh yeah and there are no bUg$ of course, but when you find any let me know.

KevinKelley Wed 26 Sep 2012

Excellent! Definitely, it's something that Fantom's been needing. Glad to see this.

brian Thu 27 Sep 2012

Very awesome. Since we've been so bad getting a fanr repo up on fantom.org, this will be great start to get centralized place to start sharing pods.

ivan Thu 27 Sep 2012

Incredible! Just registered, going to publish couple of pods next week

kaushik Fri 28 Sep 2012

Awesome! Will move my pods there over the weekend.

dsav Fri 28 Sep 2012

I'm unable to publish, getting the following error:

ERROR: publish command failed
fanr::RemoteErr: Invalid password (invalid signature) [401]
  fanr::WebRepo.parseRes (WebRepo.fan:220)
  fanr::WebRepo.publish (WebRepo.fan:107)
  fanr::PublishCmd.publish (PublishCmd.fan:72)
  fanr::PublishCmd.run (PublishCmd.fan:43)
  fanr::Main.main (Main.fan:52)
  java.lang.reflect.Method.invoke (Unknown)
  fan.sys.Method.invoke (Method.java:559)
  fan.sys.Method$MethodFunc.callOn (Method.java:230)
  fan.sys.Method.callOn (Method.java:139)
  fanx.tools.Fan.callMain (Fan.java:175)
  fanx.tools.Fan.executeType (Fan.java:140)
  fanx.tools.Fan.execute (Fan.java:41)
  fanx.tools.Fan.run (Fan.java:298)
  fanx.tools.Fan.main (Fan.java:336)

I registered just half an hour ago, is this relevant? Fantom versiono is 1.0.63. My account there is dsav, too.

tcolar Fri 28 Sep 2012

I'm not sure what happen, i know a couple others where able to use it.

I don' have the reset password feature yet (next TODO) so I removed your account. Feel free to recreate it with a new password and see if it works then.

if not let me know what os you are on, in case it's maybe a windows thing ?

Thanks

yliu Mon 1 Oct 2012

This is pretty awesome.

katox Mon 1 Oct 2012

Great idea and most needed thing. Thanks!

tcolar Wed 3 Oct 2012

I know some of you where not able to publish.

I completely forgot there was an issue with fanr encryption signature that Brian fixed for me in the Fantom sources (http://hg.fantom.org/fan-1.0/rev/fd7f21f9ad7c)

That has not been part of a release yet, so publish fails unless you use teh latest fanr (from sources).

In the meantime guess i can publish the pod for you if you email it to me ir point me to the sources, or I might temporarily disable signature/passord check until the next Fantom release.

tcolar Thu 15 Nov 2012

I made a few changes to this

  • Web based pod upload. Since the upload via fanr still won't work until the next Fantom release, in the mean time you can upload a pod via the browser. Go to http://repo.status302.com/login and after logging in go to http://repo.status302.com/mypods and there is now a form you can use to upload pods.
  • Automated pod doc generation. When a pod is uploaded the doc is generated automatically. For example : http://repo.status302.com/doc/draft/ The docs cross-links to fantom.org docs for standrad pods for easy navigation.

andy Thu 15 Nov 2012

Automated pod doc generation

Saw that earlier - very nice.

tcolar Fri 21 Dec 2012

Now that Fantom 1.0.64 is released, this all works properly (authentication).

In case anybody was waiting for this to be fixed ;)

SlimerDude Wed 13 Mar 2013

Hi Tcolar,

This may be a contentious issue, but could you add a means to allow users to delete their pods?

tcolar Wed 13 Mar 2013

First, thanks for using i, I was wondering if it would veer happen ;)

Yes that was designed this way by design. For private pods you can delete, for public ones you can't because that could lead to broken dependencies etc ..

I think what I could do is check if a pod has any dependencies and only allow deletion if it doesn't, of course it could still be an issue if the dependency is outside of this repo but I guess we can trust the owner judgment on that.

Anyway, in the meantime I can delete your pod(s) for you just email me. tcolar At colar.net

BTW: which user case is it:

  • you want to remove/replace a specific revision ?
  • you changed your mind about publishing it publicly
  • other ?

Thanks

SlimerDude Wed 13 Mar 2013

First, thanks for using it

I meant to support it ages ago, it's just taken me this long look up a licence and check what other meta props I needed. The repo is a good idea and nicely implemented.

The Pod upload form is useful, as being a Win7 64-bit user I'm limited to Fantom 1.0.63.

My use case is to replace a specific version with minor Fandoc updates. I guess I should have published it as private first, then upgraded to public.

A couple of small thoughts on the app:

  • Under Pod Details, how about making org.uri a link
  • Add No Of Downloads column on the My Pods page
  • Mention in the FAQ that you can delete private pods but not public ones
  • It'd be great if Display Documentation could be enhanced to display a default .fandoc file for the Pod, say, pod.fandoc. Future enhancements could also disp a table of contents from index.fog - see docLang.pod

tcolar Wed 13 Mar 2013

I think replacing a version is what I feel most strongly against because there s nothing worse than having multiple users with the "same" version that's not actually the same code ;)

I know changing the fandoc or meta is not really a code change so I considered maybe allowing that although in the end it's still a different pod with the same version.\\

Anyway this does seem to happen somewhat often in real life, myself included, so maybe I should allow the owner to do it with some big warning "supporting this is gonna be a mess, are you sure ?" :) and sill only if no dependencies.

Under Pod Details, how about making org.uri a link

Yeah for sure, I think I just forgot to do that

Add No Of Downloads column on the My Pods page

Yeah, had that in my todo

Mention in the FAQ that you can delete private pods but not public ones

Hu, it does :) "A private pod can be removed by it's owner, but a public pod can never be removed."

It'd be great if Display Documentation could be enhanced to display a default .fandoc >file for the Pod, say, pod.fandoc. Future enhancements could also disp a table of > contents from index.fog - see docLang.pod

Yeah I have that in my todo as well, was also thinking if their is a git/hg repo linked then maybe pull up the readme as well.

Thanks for the feedback.

andy Wed 13 Mar 2013

Anyway this does seem to happen somewhat often in real life, myself included, so maybe I should allow the owner to do it with some big warning "supporting this is gonna be a mess, are you sure ?" :) and sill only if no dependencies.

Maybe a little annoying - but I'd keep the rules simple - can never modify a version once its been published.

tcolar Wed 13 Mar 2013

Hey Andy, weren't you not the first one to run into that ? well other than myself anyway :)

I think what I will do is make it easier for myself(admin) to do that if requested (special request), pretty much i think it's only ok if it was a brand new pod that has not been downloaded yet.

@slimmerdude : I was lazy to do remove those by "hand" but just wasted an hour trying to find a decent Mongo web UI unsuccessfully ... I should just have added an admin feature which is probably what I'll do tonight.

SlimerDude Thu 21 Mar 2013

Another minor suggestion...

The Documentation could do with a simple breadcrumb (or similar) as currently there's no easy way to navigate back to the Pod overview page.

And displaying doc/pod.fandoc on the Pod overview page would be awesome! :)

tcolar Thu 21 Mar 2013

Thanks , I'll try to look into it when I get a chance (busy lately).

also btw, it's on bitbucket: https://bitbucket.org/status302/fantorepo302 so pull requests accepted ;)

ortizgiraldo Thu 28 Mar 2013

For the newbies (like me) I just want to mention that the URL for status302's repo is

http://repo.status302.com/fanr

and it can be queried using

fanr query -r http://repo.status302.com/fanr *

Sorry if this is old news for most of you guys, but as a newbie I was trying

fanr query -r http://repo.status302.com *

and getting

ERROR: query command failed
  fanr::RemoteErr: Cannot parse response as JSON [404]
  use -errTrace for full stack trace

And it took me a while to figure it out.

tcolar Thu 28 Mar 2013

Yes I guess it should return a proper 404 rather than that error.

The proper query is :

fanr query -r http://repo.status302.com/fanr/ "*"

Also note that if you are on Linux or OSX you will want to make sure you use quotes around * otherwise the shell will send the list of all local files instead of *

tcolar Thu 28 Mar 2013

@Slimerdude I've pushed some of your suggestions: uri links, # of downloads ...

SlimerDude Thu 28 Mar 2013

:) Cheers!

I was planning on doing some bitbucket changes at some point! Hmm, I still may...

tcolar Thu 28 Mar 2013

It's not too late, I didn't implement all that you requested. I don't think I'll work on it for a few weeks, so don't hesitate.

andy Thu 28 Mar 2013

I've pushed some of your suggestions: uri links, # of downloads ...

Sweet!

Login or Signup to reply.