Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Twee?

I see a new release of Twine, but can no longer find a download for twee (not that I need the old one, but it's absence is troubling). Has twee been abandoned?
«1

Comments

  • It's still around but not in active development at this point -- you can grab it at https://github.com/tweecode/twee, I believe.
  • Can the new Twine material be used with Twee (by replacing the templates, for example)?

    If not, this new Twine is completely unusable for me - I cannot use the graphical editor.
  • Not easily, unfortunately.  The new vanilla headers are separated into several files, so at the very least you'd have to reassemble them by hand and also strip off a few bits at the end.
  • Ah. Yeah, I have no interest in the GUI either. I guess I have the functionality I need, so it's not a huge deal. But, it is a disappointment.
  • mignon, it's not as clean as having a twee compiler, but with the new StoryIncludes passage you can have a .twee file that you edit everything in,
    and a twine story file that's just the Start, StoryIncludes that points to the .twee file and StorySettings.

    This way, I can code everything in the .twee file, and use Twine to build the story.

    StorySettings doesn't seem to work unless it's in the main story file, and it'll complain about a missing Start, so you want one,
    but the Start will get overridden by the Start in the .twee file.
  • Shadow wrote:

    If not, this new Twine is completely unusable for me - I cannot use the graphical editor.


    Could you elaborate on this -- is there a reason you can't use it, or just prefer not to?
  • nomdepony wrote:

    mignon, it's not as clean as having a twee compiler, but with the new StoryIncludes passage you can have a .twee file that you edit everything in,
    and a twine story file that's just the Start, StoryIncludes that points to the .twee file and StorySettings.

    This way, I can code everything in the .twee file, and use Twine to build the story.

    StorySettings doesn't seem to work unless it's in the main story file, and it'll complain about a missing Start, so you want one,
    but the Start will get overridden by the Start in the .twee file.

    My current story consists of 27 .tw files, and it is still very early in development. I'd say the story is about 20-30K words right now, plus a fair amount of javascript and CSS. That's one of the big attractions to me was the ability to easily organize my writing how I like and use a good text editor.

    As for the GUI, it just isn't of interest to me. I've tried it and can't see myself ever being comfortable using it. If I have to use it to create stories, I'll switch to something else.

    I'm really surprised twee and Twine aren't actually sharing the same codebase, since there is a fair amount of functional overlap. But, I guess they weren't designed that way.
  • nomdepony wrote:

    mignon, it's not as clean as having a twee compiler, but with the new StoryIncludes passage you can have a .twee file that you edit everything in,
    and a twine story file that's just the Start, StoryIncludes that points to the .twee file and StorySettings.

    To elaborate, the full method of this makeshift solution is as follows:

    * Open Twine
    * Create a new story containing a StoryIncludes passage
    * Save the .tws in the same directory as all your .tw / .twee files*.
    * Put the file names* of all .tw / .twee files into the StoryIncludes passage.
    * Build the output HTML file somewhere.
    * Turn on the 'Auto Build' menu option.

    The 'Auto Build' option means that the HTML file will be rebuilt every time one of the .tw / .twee files is saved in its editor. This means you can simply refresh the file in your web browser and instantly see changes, as long as you leave Twine open in the background.

    *If you've got them in separate folders, simply place it in the nearest common ancestor folder and adjust the file names into relative paths accordingly.
  • I can Imagine twee users feeling left out with the recent advancements.

    last weekend, I was fiddling with a homebrew Story Building browser app (like the abandoned tweebox).  It would be very twee like... Something simpler than Twine2 and strictly for building stories.  It would have limitations in how you save the built story due to it being browser based but it would be allot like twee without the python or command line requirements.

    I stopped just short of embedding the story formats because I was experimenting with getting the basics working and hadn't gotten to the scope phase of the concept.  I wasn't sure if i should make individual versions for each story format (drag in source(s), download).  or go all out with radio options and a file management interface.

    I'm now leaning towards the first option.  Quick and simple, drag=>drop=>download.  functionality. 

    Would you be interested in something like this?
  • L wrote:

    nomdepony wrote:

    mignon, it's not as clean as having a twee compiler, but with the new StoryIncludes passage you can have a .twee file that you edit everything in,
    and a twine story file that's just the Start, StoryIncludes that points to the .twee file and StorySettings.

    To elaborate, the full method of this makeshift solution is as follows:

    * Open Twine
    * Create a new story containing a StoryIncludes passage
    * Save the .tws in the same directory as all your .tw / .twee files*.
    * Put the file names* of all .tw / .twee files into the StoryIncludes passage.
    * Build the output HTML file somewhere.
    * Turn on the 'Auto Build' menu option.

    The 'Auto Build' option means that the HTML file will be rebuilt every time one of the .tw / .twee files is saved in its editor. This means you can simply refresh the file in your web browser and instantly see changes, as long as you leave Twine open in the background.

    *If you've got them in separate folders, simply place it in the nearest common ancestor folder and adjust the file names into relative paths accordingly.


    I guess this would be OK if I decide to switch to the new system, but I would much prefer a command line compiler. Currently, I have a python script that builds my twee app for me using find and a few other command line tools to assemble the twee command. So, I do nothing but edit text files and hit the up array to reuse the previous command. It opens the game up in chrome for me if the twee compiler succeeded, so it's completely invisible to me even if I have done some major rearrangement of passages into new files.

    As for Hanks offer, I have no idea what tweebox is, so I can't say:) If it's a tool that builds a Twine project out of twee code, I guess I might, but, again, I want to avoid doing anything other than writing my story...at least as much as possible:) And I don't want the tools to get in the way.

    I know that there are much, much larger Twine games out there than mine is, but I don't want to have to scroll forever looking for a particular passage when I can just use grep to find what I'm looking for and go right to the file. Also, using TextWrangler, I get spell checking built into my editor, which I don't think Twine has and the syntax highlighting is OK. Hardly the best, but it's sufficient for my needs. Twine probably does a better job at that, since it really understands the syntax.
  • I was also a little miffed about the lack of an updated twee, since I use linux and am far too lazy to set up Twine to run under WINE.

    I wasn't, however, too lazy to completely reimplement twee in a new language, using the new template format. I can't really in good faith recommend that other people use this; I threw it together in six hours and I'm really not sure if I'm actually parsing to tiddlywiki format properly, or using the same templating rules as Twine 1.4 does -- since my only reference for this were the 1.4 target files and the outdated twee code -- but it seems to have all the 1.4 functionality with the same interface as twee, so if anyone is really desperate to upgrade and happens to have Haskell dev tools already installed, well, have at it.

    I might see if I can fiddle with the existing twee code and get that up-to-date, but I don't know python at all, so don't hold your breath. :V
  • In theory (and this is a big theory) you should be able to run Twine on Linux from the source code if you have Python and wxPython installed. Obviously how you do this differs based on what distro you're running, and there are probably some pitfalls along the way -- which would make it a great subject for a wiki article if someone is so motivated! I used to run Linux many years ago, but not now.

    To be honest, before this topic came up, I did not think too many people used twee nowadays. While my focus right now is on developing Twine 2, I don't see why the core couldn't be adapted as, say, a Node-based command line tool someday.
  • Just chiming in as another user who much prefers Twee to Twine. For the sake of the person who asked why someone might not be able to use Twine at all--perhaps visual impairment? I don't imagine that Twine is very friendly to blind users, even if it is fully accessible to a screen reader.

    Fellow twee users, the SugarCube header provides many of the same or similar features as the 1.4 release of Twine, and works with both 1.35 and 1.4.

  • klembot wrote:

    In theory (and this is a big theory) you should be able to run Twine on Linux from the source code if you have Python and wxPython installed. Obviously how you do this differs based on what distro you're running, and there are probably some pitfalls along the way -- which would make it a great subject for a wiki article if someone is so motivated! I used to run Linux many years ago, but not now.

    To be honest, before this topic came up, I did not think too many people used twee nowadays. While my focus right now is on developing Twine 2, I don't see why the core couldn't be adapted as, say, a Node-based command line tool someday.


    I'd say there are several of us, since there is a small sampling here. If it's possible to keep the code clean enough so that you can work on a Twee compiler once Twine 2 is stable, then that would be great.

    As for Erik's suggestion, I totally agree. I'm using SugarCube and am very pleased with it. So much so, that when I saw the list of the 1.4 stuff, I couldn't really decide that there was anything new for me there.

    Xax, if you are interested in having others use your code, I'd be happy to try it. But...what in the world is a .hs file? :)
  • mignon wrote:
    But...what in the world is a .hs file? :)

    A Haskell source code file.
  • mignon wrote:

    Xax, if you are interested in having others use your code, I'd be happy to try it. But...what in the world is a .hs file? :)


    .hs is Haskell. ( http://www.haskell.org/haskellwiki/Haskell )
  • This might be of interest to you fellow command line users: I made an updated "twee" script which uses the Twine code and data to do its work, so it is much easier to keep it in sync with Twine's development. A few hours later webbedspace accepted the pull request into Twine's git master branch. So it should become available in Twine 1.4.1, I think.

    The script is actually pretty small (83 lines including a lot of empty ones), since TiddlyWiki was already designed to be used in different contexts. The TweeApp class defines two properties and two methods and the rest is just command line parsing.

    If there are any problems or feature requests, please let me know.
  • Thats great news mth.  I never did get around to finishing that drag-n-drop story builder.  Twee is faster anyway. :-)

    I for one have found myself using Twine to rough out a story's structure and usually end up writing the rest in souce code.  It's nice to be able to cut out the middle man.

    You have my gratitude.
  • Thanks, mth!
  • mth, how do we use it?
  • narF wrote:

    mth, how do we use it?


    Grab the Twine source from Git. Add the Twine source dir to your PATH, or symlink it from a directory that is in your PATH. Then run "twee" on the command line like this:

    twee story.tw > story.html
    If you want to use SugarCube, unzip a recent SugarCube release ZIP under the "targets" directory. Then run:

    twee -t SugarCube story.tw > story.html
    On Windows you'll probably have to wrap it in a batch file that executes Python with "twee" as the argument.
  • When I run twee in the terminal, I get this error:
    env: python2: No such file or directory
    note: I'm on Mac OSX 10.9.1
  • Strange, I have 10.9.1 on my MacBook as well and /usr/bin/python2 exists there.

    Does "ls -la /usr/bin/python*" print anything?
  • I get this:
    $ ls -la /usr/bin/python*
    -rwxr-xr-x 2 root wheel 58608 27 oct 22:19 /usr/bin/python
    -rwxr-xr-x 5 root wheel 925 25 ao 03:09 /usr/bin/python-config
    lrwxr-xr-x 1 root wheel 75 27 oct 22:19 /usr/bin/python2.5 -> ../../System/Library/Frameworks/Python.framework/Versions/2.5/bin/python2.5
    lrwxr-xr-x 1 root wheel 82 27 oct 22:19 /usr/bin/python2.5-config -> ../../System/Library/Frameworks/Python.framework/Versions/2.5/bin/python2.5-config
    lrwxr-xr-x 1 root wheel 75 27 oct 22:19 /usr/bin/python2.6 -> ../../System/Library/Frameworks/Python.framework/Versions/2.6/bin/python2.6
    lrwxr-xr-x 1 root wheel 82 27 oct 22:19 /usr/bin/python2.6-config -> ../../System/Library/Frameworks/Python.framework/Versions/2.6/bin/python2.6-config
    lrwxr-xr-x 1 root wheel 75 27 oct 22:19 /usr/bin/python2.7 -> ../../System/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7
    lrwxr-xr-x 1 root wheel 82 27 oct 22:19 /usr/bin/python2.7-config -> ../../System/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7-config
    -rwxr-xr-x 2 root wheel 58608 27 oct 22:19 /usr/bin/pythonw
    lrwxr-xr-x 1 root wheel 76 27 oct 22:19 /usr/bin/pythonw2.5 -> ../../System/Library/Frameworks/Python.framework/Versions/2.5/bin/pythonw2.5
    lrwxr-xr-x 1 root wheel 76 27 oct 22:19 /usr/bin/pythonw2.6 -> ../../System/Library/Frameworks/Python.framework/Versions/2.6/bin/pythonw2.6
    lrwxr-xr-x 1 root wheel 76 27 oct 22:19 /usr/bin/pythonw2.7 -> ../../System/Library/Frameworks/Python.framework/Versions/2.7/bin/pythonw2.7
  • It would probably be simplest to edit the first line of your twee file.  Change this:
    #!/usr/bin/env python2
    To this:
    #!/usr/bin/env python

    Alternatively, you could add a symlink for python2 pointing to python2.7.  For example:

    cd /usr/bin
    ln -s ../../System/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7 python2
  • I tried that already. Chanded the 1st line in the twee to remove the '2'. It doesn't work. When I run it, I get this error:
    Traceback (most recent call last):
    File "./twee", line 7, in <module>
    from tiddlywiki import TiddlyWiki
    File "/Users/narF/Documents/a moi/game dev/Twine/twee1.4.1/tiddlywiki.py", line 14, in <module>
    from tweelexer import TweeLexer
    File "/Users/narF/Documents/a moi/game dev/Twine/twee1.4.1/tweelexer.py", line 1, in <module>
    import re, wx, wx.stc
    ImportError: No module named wx
  • Yes, but at least it's finding python now.  That error is something else.

    If you followed mth's instructions, you should have a twee file in the root of your Twine directory.  It now comes along with Twine (although I don't think a release version of Twine has shipped with it yet, which is why you have to get it from the github repo at the moment).  Where did that twee1.4.1 directory inside your Twine directory come from?
  • Ok nice! We're making progress! :D

    The folder "twee1.4.1" that you see is the Twine folder that I got from https://github.com/tweecode/twine. I renamed it to "twee1.4.1" to differentiate it from previous versions.

    The parent folder "Twine" that I have is were I keep all my stories and Twine and softwares.

    I hope this clarifies my folder hierarchy! :)

    Could the error occurs because I have an accented "" in my path?

    Also, I remember that for the old twee1.7.1, I had to change a line to make it work, according to a forum post that I read long ago. At line number 88, I had to change this
    print tw.toHtml()
    into this:
    print tw.toHtml(scriptPath)
    Could it be the same problem?
  • The "No module named wx" error means that Twee tried to import wxWidgets, which is the GUI toolkit that Twine uses. Twee is a command line tool and therefore shouldn't depend on wxWidgets. I'll have a look at the code and try to remove that dependency.

    Edit: Please test with this Git branch. The dependency of Twee on wxWidgets is removed there, by splitting up the module that caused wxWidgets to be imported.
  • Ah I see.
    Keep me posted if you have a fix. I'll be glad to help test it. In the meantime, I reverted to my old twee1.7.1 with the old story formats.
Sign In or Register to comment.