Skip to content

robsman/scala-js.g8

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Giter8 Template for Scala.js

What is giter8?

"Giter8 is a command line tool to generate files and directories from templates published on github or any other git repository"

Using this giter8 template you can easily generate a Scala.js project where this is set-up automatically for you:

  • a custom name
  • a custom package structure

It saves you the work of having to manually update the directory structure, Scala classes, HTML and JavaScript files.

Installation

Installing giter8

To install giter8 for the first time, follow the installation instructions on the official page.

If you already have giter8 installed, but it's from before 30th April 2014, you need to upgrade (if in doubt, upgrade).

First, clean-up the conscript cache with:

cs --clean-boot

Afterwards, re-install giter8 with:

cs n8han/giter8

Usage

Creating Scala.js projects

From the command line, run:

g8 sebnozzi/scala-js.g8

(Note how this schema points to this project on github)

You will be asked for:

  1. Version,
  2. Organization,
  3. Name,
  4. Package Name (simply accept the default value as it is derived from the previously entered Organization and Name) and
  5. Class Name (simply accept the default value as it is derived from the previously entered Name)

of your project.

After enter the requested information your project structure will be created (note that in the example above the version was left blank and thus default value was taken).

Sample session:

# g8 sebnozzi/scala-js.g8

Scala.js Project 

version [0.1-SNAPSHOT]:
organization [org.example]: com.sebnozzi
name [ScalaJS Example]: My Cool Project
packageName [com.sebnozzi.mycoolproject]:
className [MyCoolProject]:

Template applied in ./my-cool-project

# cd my-cool-project
# sbt

You can now use you Scala.js project as expected: packageJS, test, optimizeJS should all work from SBT.

About

Giter8 Template for Scala.js Projects

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Scala 100.0%