0.1.21 • Published 9 years ago

to-utf8-unix v0.1.21

Weekly downloads
11
License
MPL-2.0
Repository
github
Last release
9 years ago

Introduction

It converts the character encodings of given files to UTF-8 and converts every end of line into a newline character '\n'.

Dependencies to be manually installed

  • icu

Usage

npm install -g to-utf8-unix
to-utf8-unix /path/to/file1 ...

Development Setup

  • Install npm and leiningen.
  • lein npm install
  • Launch clojure REPL via
    • lein repl on a shell
    • cider-jack-in on emacs
    • etc...
  • Launch figwheel REPL on clojure REPL by executing (launch-figwheel-repl).
  • Start figwheel in a terminal window
node target/server_dev/to-utf8-unix.js
  • Changes to your source code will trigger incremental compilation.
  • Or, instead of figwheel REPL, launch clojurescript REPL on clojure REPL with
(launch-cljs-repl)

Structure

src/cljs

contains executable code. It is compiled to index.js.

to-utf8-unix internally uses buffer_descriptor. buffer_descriptor is defined as

{"charset" : String, "confidence" : Number, "message" : String,
 "buffer" : Buffer, "save" : true|false}

src/clj

contains repl functions (launch-figwheel-repl) and (launch-cljs-repl). It is not part of clojurescript build.

Production Build

lein cljsbuild once prod

builds an executable as index.js

Note that you don't have to include index.js in your source code repository.

Deployment

  • lein deploy clojars deploys src/cljs on clojars
  • lein npm publish deploys index.js on npm

License

Copyright © 2015 crocket

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.

0.1.21

9 years ago

0.1.20

9 years ago

0.1.19

9 years ago

0.1.18

9 years ago

0.1.17

9 years ago

0.1.16

9 years ago

0.1.15

9 years ago

0.1.14

9 years ago

0.1.13

9 years ago

0.1.12

9 years ago

0.1.11

10 years ago

0.1.10

10 years ago

0.1.9

10 years ago

0.1.8

10 years ago

0.1.7

10 years ago

0.1.6

10 years ago

0.1.5

10 years ago

0.1.4

10 years ago

0.1.3

10 years ago

0.1.2

10 years ago

0.1.1

10 years ago

0.1.0

10 years ago