Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@


[![Build Status](https://travis-ci.org/coderplanets/coderplanets_server.svg?branch=dev)](https://travis-ci.org/coderplanets/coderplanets_server)
[![Coverage Status](https://coveralls.io/repos/github/coderplanets/coderplanets_server/badge.svg?branch=dev)](https://coveralls.io/github/coderplanets/coderplanets_server?branch=dev)
[![codecov](https://codecov.io/gh/coderplanets/coderplanets_server/branch/dev/graph/badge.svg)](https://codecov.io/gh/coderplanets/coderplanets_server)
[![Inline docs](http://inch-ci.org/github/coderplanets/coderplanets_server.svg)](http://inch-ci.org/github/coderplanets/coderplanets_server)
[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)
Expand Down
6 changes: 0 additions & 6 deletions docs/Deployment.md

This file was deleted.

Empty file added docs/FAQ.md
Empty file.
32 changes: 31 additions & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
@@ -1 +1,31 @@
# TODO
## Table of Contents

- [Architecture](architecture)
- [Intro](architecture/intro.md)
- [GraphQL](architecture/grqphQL.md)
- [Development](development)
- [Intro](development/intro.md)
- [Setup](development/setup.md)
- [Console](development/console.md)
- [Linter](development/linter.md)
- [Generator](development/generator.md)
- [Deployment](deployment)
- [Intro](deployment/intro.md)
- [Release](deployment/release.md)
- [Testing](testing)
- [Unit Testing](testing/unit-testing.md)
- [GraphQL Testing](testing/graphql-testing.md)
- [Analysis](analysis)
- [Apollo Engine](analysis/apollo-engine.md)
- [Error Tracking](analysis/error-tracking.md)
- [CI](ci)
- [Intro](ci/intro.md)
- [Test Coverage](ci/test-coverage.md)
- [Doc Coverage](ci/doc-coverage.md)
- [Commit Msg Lint](ci/commit-msg-lint.md)
- [schema check](ci/schema-check.md)
- [Roadmap](Roadmap.md)
- [FAQ](FAQ.md)
- [Contributing](Contributing.md)
- [Troubleshooting](Troubleshooting.md)

1 change: 0 additions & 1 deletion docs/all.json

This file was deleted.

Empty file added docs/analysis/apollo-engine.md
Empty file.
3 changes: 3 additions & 0 deletions docs/analysis/error-tracking.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@

[错误报告](https://sentry.io/welcome/)
[sentry-elixir](https://github.com/getsentry/sentry-elixir)
Empty file added docs/architecture/graphql.md
Empty file.
Empty file added docs/ci/commit-msg-lint.md
Empty file.
Empty file added docs/ci/doc-coverage.md
Empty file.
Empty file added docs/ci/intro.md
Empty file.
Empty file added docs/ci/schema-check.md
Empty file.
Empty file added docs/ci/test-coverage.md
Empty file.
Empty file added docs/contributing.md
Empty file.
Empty file added docs/deployment/intro.md
Empty file.
Empty file added docs/deployment/release.md
Empty file.
Empty file added docs/development/console.md
Empty file.
65 changes: 65 additions & 0 deletions docs/development/generator.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@



## run your project

```sh
env MIX_ENV=mock iex -S mix

mix test.watch test/mastani_server/cms/cms_passport_test.exs --only wip

mix ecto.gen.migration add_xxx


env MIX_ENV=test mix ecto.drop
env MIX_ENV=test mix ecto.create

support history in iex:
bash: export ERL_AFLAGS="-kernel shell_history enabled"
fish: set -g -x ERL_AFLAGS "-kernel shell_history enabled"
```
`recompile()` to recompile your project

[tips#6](https://medium.com/blackode/10-killer-elixir-tips-2-c5f87f8a70c8)

但是 config/config.ex 中配置的改变需要重新编译

## run cmd for specific env

```sh
env MIX_ENV=test mix ecto.setup
```

this cmd only preform on `mastani_server_test` databse


## prod

```sh
env PORT=4001 MIX_ENV=prod mix ecto.setup
```

```sh
env PORT=4001 MIX_ENV=prod mix phx.server
```


## mock

```sh
env MIX_ENV=mock mix ecto.setup
```

```sh
env PORT=4001 MIX_ENV=mock mix phx.server
```

```sh
env MIX_ENV=mock mix run priv/mock/user_seeds.exs
```

## mock data

```sh
env MIX_ENV=mock iex -S mix phx.server
```
Empty file added docs/development/intro.md
Empty file.
Empty file added docs/development/linter.md
Empty file.
Empty file added docs/development/setup.md
Empty file.
45 changes: 0 additions & 45 deletions docs/ideas.md

This file was deleted.

Empty file added docs/roadmap.md
Empty file.
Empty file added docs/testing/graphql-testing.md
Empty file.
Empty file added docs/testing/unit-testing.md
Empty file.
31 changes: 0 additions & 31 deletions docs/tips.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,34 +62,3 @@ env MIX_ENV=mock mix run priv/mock/user_seeds.exs
```sh
env MIX_ENV=mock iex -S mix phx.server
```

## Guardian

[胖子 comeonin 那集视频](https://www.youtube.com/watch?v=UK8KBnoidr4)
[Permissions pm doc](https://hexdocs.pm/guardian/Guardian.Permissions.Bitwise.html#content)
[Permissions blog doc](http://blog.overstuffedgorilla.com/simple-guardian-permissions/)
[api authentication blog](http://blog.overstuffedgorilla.com/simple-guardian-api-authentication/)

## packages

[翻页](https://snippets.aktagon.com/snippets/776-pagination-with-elixir-and-ecto)
[翻页](https://github.com/drewolson/scrivener_ecto)
[邮件](https://github.com/thoughtbot/bamboo)

[CI: circleci](https://blog.lelonek.me/elixir-continuous-integration-with-circleci-ceae93dbe011)
[错误报告](https://sentry.io/welcome/)
[sentry-elixir](https://github.com/getsentry/sentry-elixir)
[run phoenix in docker](https://blog.lelonek.me/how-to-run-phoenix-framework-application-inside-a-docker-container-b02817d860b4)


## snippets

examise.io ...
[Elixir fishy coding lines and snippets](https://medium.com/blackode/elixir-fishy-coding-lines-and-snippets-7cdd995e5ad4)
[Elixir killer tips](https://medium.com/blackode/10-killer-elixir-tips-2a9be1bec9be)
[Elixir 专题](https://medium.com/blackode/tagged/elixir) 很棒


## keynote

[ActiveRecord 和 Ecto 的比较](http://tony612.com/activerecord-vs-ecto)
Empty file added docs/troubleshooting.md
Empty file.