Giter Site home page Giter Site logo

drumanagh / twine-wrapper Goto Github PK

View Code? Open in Web Editor NEW
20.0 3.0 5.0 1.46 MB

twine-wrapper is an NW.js app builder for your exported Twine story, to turn it into a self-contained app for Windows, OS X, or Linux.

License: MIT License

JavaScript 2.60% HTML 97.40%

twine-wrapper's Introduction

This project is dramatically out of date and deprecated. Use klembot/twinejs instead.

twine-wrapper

twine-wrapper is an NW.js app builder for your exported Twine story, to turn it into a self-contained app for Windows, OS X, or Linux.

Getting started

To get a copy of twine-wrapper, you'll need to either manually download it, or use git and run git clone https://github.com/drumanagh/twine-wrapper.git where you want the twine-wrapper folder to be downloaded.

To use the automatic build process, you'll need to have Node.js installed.

  • On OS X, you can install Node.js by installing Homebrew, then running brew install node in a terminal window.
  • On Windows, you can install Node.js by installing Chocolatey, then running choco install nodejs in a command window.

Once Node is installed, you'll need to use npm install -g grunt-cli and npm install -g bower in a terminal or command window to install Grunt and Bower respectively, which are used for the build process.

On OS X, you'll also need to have Wine installed to use Windows app icons. Once you have Homebrew, you can install it with brew install wine.

Once you have this all in place, you'll need to open that twine-wrapper folder in a terminal or command window, then run npm install and bower install to automatically set up the miscellaneous fiddly bits used in the build process.

Setting up your story

You'll need to export your story from Twine and save it as index.html in the story folder inside the twine-wrapper folder.

Once it's there, take a look at the package.json file in the story folder, and edit it with the details of your story. The important bits are the name, homepage and bug reporting page (if any), and the author information. You'll also want to choose whether to put your story under a license, which can allow others to make derivative works, or whether to leave it unlicensed.

If you have custom Windows or Mac icons, you can replace the ico and icns files in the story folder with them. These will automatically be included when the app is built.

app.js is where the toolbar menus are built. This has some sane defaults included already to make the app look like a native one, but it should be fairly easy to add or change items using the existing ones as a template if you want links that go to specific websites. See the NW.js wiki for menu documentation.

The about.html file is what's loaded when you view Help -> About or, on a Mac, the About item under the app's menu title. You can toss whatever HTML into there, though you'll want to stick to the basics for it to render properly in the Mac About box.

Building the app

If you have everything set up, you should be able to run grunt build at a command line in the twine-wrapper folder. Everything will be put together automatically, and once it's done apps for Windows, OS X, and Linux will be set up in the build folder under twine-wrapper.

twine-wrapper's People

Contributors

drumanagh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

twine-wrapper's Issues

Does this project still work?

Hello, I realize the most recent commits for this project are almost 3 years ago so I'm being extremely optimistic but should this project still work? I tried building a simple Twine story in Mac OS 10.14 and it builds but when I run the MacOS executatable I get a default NW.js start screen.

Menu items perform Twine functions

Hello,

This is a great project and I'm really happy it exists.

My feature request is to include menu items which mirror the Redo/Undo functions of Twine buttons.

So for example if the user chooses File->Undo, the action would be the same as clicking on the Undo button in the Twine story.

Thank you for considering adding this!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.