Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
PySh: an attempt to create a shell providing both bash and Python features (aspyct.org)
33 points by gasull on June 11, 2009 | hide | past | favorite | 18 comments


They used one of my favorite licenses, the FSF-approved WTFPL:

            DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE 
                    Version 2, December 2004 

 Copyright (C) 2004 Sam Hocevar 
  14 rue de Plaisance, 75014 Paris, France 
 Everyone is permitted to copy and distribute verbatim or modified 
 copies of this license document, and changing it is allowed as long 
 as the name is changed. 

            DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE 
   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 

  0. You just DO WHAT THE FUCK YOU WANT TO.


Personally I hate licenses like this. At least this one has been approved by the FSF, but I have to look it up. I see no reason not to just use MIT/BSD if you want a short, permissive license. That way everyone knows exactly what they can do with it and programmers hoping to use your code won't have to beg the legal department to ok it.


I agree. If you really want something extremely permissive just go the SQLite route. Otherwise BSD/MIT (BSD is my fav). There seems little use for this license.


I can understand your concern about having to get yet another license approved by the legal department. If you're interested, the author explains his problems with public domain and the BSD license here: http://sam.zoy.org/wtfpl/


That is strange that this is FSF approved to me...

In the US at least, without the typical "AS IS" warning (as you would see in the MIT license which seems just as good for the intended purpose of the WTFPL), this is creating an unintended liability?

http://www.linuxjournal.com/article/6225


From the WTFPL site:

Why is there no “no warranty” clause?

The WTFPL is an all-purpose license and does not cover only computer programs; it can be used for artwork, documentation and so on. As such, it only covers copying, distribution and modification. If you want to add a no warranty clause for a program, you may use the following wording in your source code:

  /* This program is free software. It comes without any warranty, to
 * the extent permitted by applicable law. You can redistribute it
 * and/or modify it under the terms of the Do What The Fuck You Want
 * To Public License, Version 2, as published by Sam Hocevar. See
 * http://sam.zoy.org/wtfpl/COPYING for more details. */


Thanks. I see that the pysh person states "with a no warranty close [sic]". Did not catch that.


> this is creating an unintended liability

If you want to sell WTFPL-licensed software, you should probably relicense it under the MIT (or BSD, or GPL) license. Then you are safe.

The original author that put some code on a web page is probably not going to be liable anyway.


There already exists Pyshell ( http://pyshell.sourceforge.net/ ). Pyshell is a lot more mature, PySh is more a proof of concept.


Awesome, who knew that bash could be (more or less) reimplemented in another language('s interpreter) in less than 300 lines? I sure as hell didn't. This bash script is the trump card to all of my previous excuses for why I don't want, need, or care to learn Python. . .thanks Antoine. . .I just got sold.

Ask thread: who here uses Zsh? does anyone actually think they're more productive in their shell than they are in bash? why do you think this? can you prove it?


I use fish about just as often as I use BASH. It has some really nice features, like tabbed multiline editing and syntax highlighting...

http://fishshell.org/index.php

In my experience: It tab completes faster than bash, but is slower when it comes to some other things. It's pretty young as far as shells go, and has some irritating bugs...


PySH is not bash.

  /tmp/pysh > [[ -d test ]]
  Unknown command: [[ -d test ]]


zsh tab-completes command options (in freebsd, anyway. doesn't seem to work in osx).


So does bash.

http://bash-completion.alioth.debian.org/

It's extensible to boot.


How does this work with whitespace? Do you have to indent if you are going multi-line?


Yeah it seems like ruby would be a better fit here, as much as I like python.


Perhaps they can import the Haskell-rules. Haskell allows indentation and curly braces/semicolons to be mixed at will.


I've always fancied an interactive (ruling out scsh) sexp based shell. At the prompt Bourne compatibility doesn't matter to me.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: