mirror of
https://github.com/NoRedInk/noredink-ui.git
synced 2025-01-08 07:27:44 +03:00
Merge pull request #1358 from NoRedInk/component-catalog-rebundling
move component-catalog-app back under component-catalog/src
This commit is contained in:
commit
1e02d8564a
3
.gitignore
vendored
3
.gitignore
vendored
@ -6,9 +6,6 @@ elm-stuff
|
||||
# elm-repl generated files
|
||||
repl-temp-*
|
||||
|
||||
### Styleguide App
|
||||
component-catalog-app/bundle.js
|
||||
|
||||
### Emacs ###
|
||||
# -*- mode: gitignore; -*-
|
||||
*~
|
||||
|
@ -1,4 +1,3 @@
|
||||
elm-stuff/
|
||||
src/
|
||||
component-catalog-app/
|
||||
tests/
|
||||
|
@ -96,7 +96,7 @@ main = do
|
||||
cmd (WithStdout True) (FileStdout out) "elm-review"
|
||||
|
||||
"log/elm-review-component-catalog.txt" %> \out -> do
|
||||
elmFiles <- getDirectoryFiles "." ["component-catalog/**/*.elm", "component-catalog-app/**/*.elm"]
|
||||
elmFiles <- getDirectoryFiles "." ["component-catalog/**/*.elm"]
|
||||
need (["package.json", "component-catalog/elm.json"] ++ elmFiles)
|
||||
cmd (Cwd "component-catalog") (WithStdout True) (FileStdout out) "elm-review"
|
||||
|
||||
@ -110,7 +110,7 @@ main = do
|
||||
writeFileChanged out "formatting checks passed"
|
||||
|
||||
"log/elm-format.txt" %> \out -> do
|
||||
let placesToLook = ["src", "tests", "component-catalog", "component-catalog-app"]
|
||||
let placesToLook = ["src", "tests", "component-catalog"]
|
||||
elmFiles <- getDirectoryFiles "." (map (\place -> place </> "**" </> "*.elm") placesToLook)
|
||||
need elmFiles
|
||||
cmd (WithStdout True) (FileStdout out) "elm-format" "--validate" placesToLook
|
||||
@ -156,9 +156,9 @@ main = do
|
||||
cmd_ "./node_modules/.bin/browserify" "--entry" "component-catalog/manifest.js" "--outfile" out
|
||||
|
||||
"public/elm.js" %> \out -> do
|
||||
elmSources <- getDirectoryFiles "." ["component-catalog-app/**/*.elm", "src/**/*.elm"]
|
||||
elmSources <- getDirectoryFiles "." ["component-catalog/src/**/*.elm", "src/**/*.elm"]
|
||||
need elmSources
|
||||
cmd_ (Cwd "component-catalog") "elm" "make" "Main.elm" "--output" (".." </> out)
|
||||
cmd_ (Cwd "component-catalog") "elm" "make" "src/Main.elm" "--output" (".." </> out)
|
||||
|
||||
"public/package.json" %> \out -> do
|
||||
copyFileChanged "elm.json" out
|
||||
|
@ -1,8 +1,8 @@
|
||||
{
|
||||
"type": "application",
|
||||
"source-directories": [
|
||||
"../component-catalog-app",
|
||||
"../src"
|
||||
"../src",
|
||||
"src"
|
||||
],
|
||||
"elm-version": "0.19.1",
|
||||
"dependencies": {
|
||||
|
@ -22,7 +22,7 @@ config : List Rule
|
||||
config =
|
||||
List.map
|
||||
(Review.Rule.ignoreErrorsForDirectories [ "../src" ]
|
||||
>> Review.Rule.ignoreErrorsForFiles [ "../component-catalog-app/App.elm" ]
|
||||
>> Review.Rule.ignoreErrorsForFiles [ "src/App.elm" ]
|
||||
)
|
||||
[ NoUnused.CustomTypeConstructors.rule []
|
||||
|
||||
|
@ -12,7 +12,7 @@ shake --compact "$SHAKE_TARGET"
|
||||
cat <<EOF
|
||||
== 👋 Hello! ==================================================================
|
||||
|
||||
I'm watching files in component-catalog, component-catalog-app, and src for changes. If you make any
|
||||
I'm watching files in component-catalog and src for changes. If you make any
|
||||
changes, I'll try to be smart about what should change (things end up in the
|
||||
"public" directory if you want to check my work.) If you remove a file and it's
|
||||
still showing up, delete the "public" directory and restart me.
|
||||
|
@ -15,7 +15,7 @@ if test -d public; then rm -rf public; fi
|
||||
mkdir public
|
||||
|
||||
# build the interactive parts
|
||||
(cd component-catalog && npx elm make Main.elm --output ../public/elm.js)
|
||||
(cd component-catalog && npx elm make src/Main.elm --output ../public/elm.js)
|
||||
npx browserify --entry component-catalog/manifest.js --outfile public/bundle.js
|
||||
|
||||
# copy static files
|
||||
|
Loading…
Reference in New Issue
Block a user