Skip to content

Commit

Permalink
Simplified install commands a bit. Added Makefile, and made editorcon…
Browse files Browse the repository at this point in the history
…fig changes.
  • Loading branch information
patcon committed Sep 24, 2024
1 parent a1326c0 commit 95ba7bd
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
root = true

# Unix-style newlines with a newline ending every file
[*]
[*.{ts,js}]
end_of_line = lf
insert_final_newline = true
indent_style = space
Expand Down
20 changes: 20 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
setup: ## Install packages and polis codebase
git submodule update --init
npm install

run: ## Run storybook development environment
npm run storybook

%:
@true

.PHONY: help

help:
@echo 'Usage: make <command>'
@echo
@echo 'where <command> is one of the following:'
@echo
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-15s\033[0m %s\n", $$1, $$2}'

.DEFAULT_GOAL := help
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,16 @@ Requirements:
git checkout https://github.com/CivicTechTO/polis-storybook
cd polis-storybook
git submodule init
git submodule update
git submodule update --init
npm install
npm run storybook
```

A browser window will open automatically: http://localhost:6006

(If you have the `make` command installed, you may run `make` to see the helper tasks it can help you run.)

## Technologies Used

- [**Storybook.**][storybook] A frontend workshop for building UI components and pages in isolation.
Expand Down

0 comments on commit 95ba7bd

Please sign in to comment.