diff options
| author | John J. Camilleri <john@digitalgrammars.com> | 2018-07-04 10:09:58 +0200 |
|---|---|---|
| committer | John J. Camilleri <john@digitalgrammars.com> | 2018-07-04 10:09:58 +0200 |
| commit | c6f4edaea5f1074ba682fac5d711016f0136998f (patch) | |
| tree | bb49b8bac2e3cafd3c1f997115bf5bb841554eab /examples/phrasebook/Update.hs | |
| parent | 00476ae38687fb7d33081130822cbd4e8f34cfd3 (diff) | |
Remove examples directory; these now live in gf-contrib
All changes have been reflected in the gf-contrib repository:
https://github.com/GrammaticalFramework/gf-contrib
Now, for WebSetup to build the example grammars, one must have gf-contrib
cloned in the same top-level directory as GF. When this isn't the case,
WebSetup displays a notice without failing.
Diffstat (limited to 'examples/phrasebook/Update.hs')
| -rw-r--r-- | examples/phrasebook/Update.hs | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/examples/phrasebook/Update.hs b/examples/phrasebook/Update.hs deleted file mode 100644 index 3d9232d61..000000000 --- a/examples/phrasebook/Update.hs +++ /dev/null @@ -1,27 +0,0 @@ -import System - -main = do - file:_ <- getArgs - updates <- readFile file >= return . readUpdates - mapM_ (doUpdate file) updates - return () - -type Update = (FilePath, [String]) - -readUpdates :: String -> [Update] -readUpdates s = [] - -doUpdate :: FilePath -> Update -> IO () -doUpdate src (target,ls) = do - s <- readFile target - let beg = dropLastBracket s - let tmp = tmpFile target - writeFile tmp beg - appendFile tmp $ unlines [(line ++ "-- UPDATE FROM " ++ src) | line <- ls] - appendFile tmp "\n}\n" - -tmpFile file = "tmp-update/"++ file - ----- quick and dirty -dropLastBracket = reverse . init . dropWhile (/='}') . reverse - |
