git.iko.soy/rowtype-yoga/purescript-protobuf
on master help sign in
Cleanup
commit087f55e1747419e0e47972f46bc3e770d2794fe8 authorJames Brock <jamesbrock@gmail.com> dateFri 18 Sep 2020, 09:39 (6 years ago) parent98d3038
5 files changed+6−6
.vscode/settings.json+1−1 shell.nix+1−1 spago.dhall−2 src/ProtocPlugin/Main.purs−2 test.dhall+4
.vscode/settings.json+1−1
@@ -1,6 +1,6 @@
11{
22 "purescript.addSpagoSources": true,
3− "purescript.buildCommand": "spago build --purs-args --json-errors ",
3+ "purescript.buildCommand": "spago build --purs-args --json-errors",
44 "purescript.sourcePath": "src test conformance",
55 "purescript.packagePath": ".spago/",
66 "purescript.addNpmPath": true
shell.nix+1−1
@@ -1,4 +1,4 @@
1−{ pkgs ? import ./nix/pkgs.nix { } }:
1+{ pkgs ? import ./nix/pkgs.nix {} }:
22let
33 conformance = import ./conformance/protobuf.nix { inherit pkgs; };
44in
spago.dhall−2
@@ -1,5 +1,3 @@
1−{-
2−-}
31{ name = "protobuf-library"
42, dependencies =
53 [ "arraybuffer"
src/ProtocPlugin/Main.purs−2
@@ -28,7 +28,6 @@ import Data.String as String
2828import Data.String.Pattern as String.Pattern
2929import Data.String.Regex as String.Regex
3030import Data.String.Regex.Flags as String.Regex.Flags
31−-- import Partial.Unsafe (unsafePartial)
3231
3332import Text.Parsing.Parser (runParserT)
3433import Data.ArrayBuffer.Builder (execPut)
@@ -226,7 +225,6 @@ import Protobuf.Runtime as Runtime
226225 underscoreToUpper = case String.Regex.regex "_([a-z])" flag of
227226 Left _ -> identity
228227 Right patt -> String.Regex.replace' patt toUpper
229− -- toUpper :: Partial => String -> Array String -> String
230228 toUpper _ [x] = String.toUpper x
231229 toUpper x _ = x
232230 flag = String.Regex.Flags.RegexFlags
test.dhall+4
@@ -7,6 +7,10 @@
77--
88-- spago -x test.dhall test
99--
10+-- Also use this for a repl:
11+--
12+-- spago -x test.dhall repl
13+--
1014
1115let conf = ./spago.dhall
1216