bounty for window users

65 views
Skip to first unread message

Massimo Di Pierro

unread,
Jun 29, 2015, 11:43:30 AM6/29/15
to web...@googlegroups.com
I offer $50 is you can do this in a couple of days:

In the web2py admin interface there is a "pack custom page" which redirects to
and has a button "download w2p".

I would like one addition button there that says "download as exe" which will do the following:
- download the latest web2py_win.zip
- unzip it (using the python API)
- copy the web2pp app in question (selected files/folders) under the unzipped web2py/applications/
- create a file routes.py under the unzipped web2py/ folder which contains
routers = dict( BASE=dict(default_application='....') )  
  where ... is the name of the app in question
- zips the unzip folder again with name web2py.app.<name>.exe and downloads it

The zip/unzip should be done in RAM using the python zip module. 
This is for those uses who develop on windows for window and expect the end users to run web2py locally with a single app. And yes, they exist. It would make their life easier and avoid zipping/unzipping mistakes and information leakage.

This should not take more than 10-20 lines in the admin app. It is also a good exercise.
I will only pay the first to deliver (if it works well) so post your solution in the form of a pull request on github.

Massimo

Niphlod

unread,
Jun 29, 2015, 2:48:38 PM6/29/15
to web...@googlegroups.com
/me restricts himself to review the code before the actual merge. if noone rescues the bounty in a week I'll do it.

Massimo Di Pierro

unread,
Jun 30, 2015, 3:31:07 AM6/30/15
to web...@googlegroups.com, nip...@gmail.com
:-)

Leonel Câmara

unread,
Jun 30, 2015, 12:56:48 PM6/30/15
to web...@googlegroups.com
Is this what you want?


I think I've done everything you asked except for the .exe part, I don't see how to turn the zipfile into an executable.

Massimo Di Pierro

unread,
Jun 30, 2015, 1:35:44 PM6/30/15
to web...@googlegroups.com, leonel...@gmail.com
90% done ;-)

 I would like the link not in the dropdown but on top of this page:


so that it would not add to the zip all the files of the app, only those checked.

Massimo

Leonel Câmara

unread,
Jun 30, 2015, 1:42:17 PM6/30/15
to web...@googlegroups.com
Ohh I'll make the modifications.

Leonel Câmara

unread,
Jun 30, 2015, 2:23:08 PM6/30/15
to web...@googlegroups.com
New version with the button in the right place and only adding the checked files

https://github.com/web2py/web2py/pull/1008

Reply all
Reply to author
Forward
0 new messages