Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit6151762

Browse files
committed
chore: Merge branch 'dev'
2 parents8d0bba9 +efc6d38 commit6151762

File tree

97 files changed

+543
-245
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

97 files changed

+543
-245
lines changed

‎.gitignore‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@ _tuts/
1919
docs/draft.ex
2020
cover/excoveralls.html
2121
node_modules/
22+
.elixir_ls/

‎.travis.yml‎

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
language:elixir
22
elixir:
3-
-1.6.6
3+
-1.9.0
44
otp_release:
5-
-20.1
6-
-21.0
5+
-22.0.5
76
node_js:
8-
-8
7+
-10
98
sudo:false
109
addons:
1110
postgresql:'9.4'

‎config/config.exs‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,11 @@ config :groupher_server, GroupherServer.Mailer,
7575
adapter:Bamboo.MailgunAdapter,
7676
domain:"mailer.coderplanets.com"
7777

78+
# handle background jobs
79+
config:rihanna,
80+
jobs_table_name:"background_jobs",
81+
producer_postgres_connection:{Ecto,GroupherServer.Repo}
82+
7883
import_config"#{Mix.env()}.exs"
7984

8085
ifFile.exists?("config/#{Mix.env()}.secret.exs")do

‎lib/groupher_server/application.ex‎

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,38 @@
11
defmoduleGroupherServer.Applicationdo
2+
@moduledocfalse
23
useApplication
34

45
# See https://hexdocs.pm/elixir/Application.html
56
# for more information on OTP Applications
67
defstart(_type,_args)do
78
importSupervisor.Spec
9+
importCachex.Spec
810

911
# Define workers and child supervisors to be supervised
1012
children=[
1113
# Start the Ecto repository
1214
supervisor(GroupherServer.Repo,[]),
1315
# Start the endpoint when the application starts
14-
supervisor(GroupherServerWeb.Endpoint,[])
16+
supervisor(GroupherServerWeb.Endpoint,[]),
1517
# Start your own worker by calling: GroupherServer.Worker.start_link(arg1, arg2, arg3)
1618
# worker(GroupherServer.Worker, [arg1, arg2, arg3]),
19+
worker(Cachex,[
20+
:site_cache,
21+
[
22+
limit:
23+
limit(
24+
# the limit provided
25+
size:5000,
26+
# the policy to use for eviction
27+
policy:Cachex.Policy.LRW,
28+
# how much to reclaim on bound expiration
29+
reclaim:0.1,
30+
# options to pass to the policy
31+
options:[]
32+
)
33+
]
34+
]),
35+
{Rihanna.Supervisor,[postgrex:GroupherServer.Repo.config()]}
1736
]
1837

1938
# See https://hexdocs.pm/elixir/Supervisor.html

‎lib/groupher_server/cms/author.ex‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@ defmodule GroupherServer.CMS.Author do
44

55
useEcto.Schema
66
importEcto.Changeset
7-
aliasGroupherServer.Accounts
8-
aliasGroupherServer.CMS.Post
7+
8+
aliasGroupherServer.{Accounts,CMS}
9+
10+
aliasCMS.Post
911

1012
@typet::%Author{}
1113

‎lib/groupher_server/cms/category.ex‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,8 @@ defmodule GroupherServer.CMS.Category do
44

55
useEcto.Schema
66
importEcto.Changeset
7+
78
aliasGroupherServer.CMS.{Author,Community}
8-
# alias GroupherServer.Accounts
9-
# alias Helper.Certification
109

1110
@required_fields~w(title raw author_id)a
1211
@optional_fields~w(index)a

‎lib/groupher_server/cms/cms.ex‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@ defmodule GroupherServer.CMS do
44
[CMS]: post, job, ...
55
[CURD]: create, update, delete ...
66
"""
7-
aliasGroupherServer.CMS.Delegate.{
7+
8+
aliasGroupherServer.CMS.Delegate
9+
10+
aliasDelegate.{
811
ArticleCURD,
912
ArticleOperation,
1013
ArticleReaction,

‎lib/groupher_server/cms/community.ex‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
defmoduleGroupherServer.CMS.Communitydo
2+
@moduledocfalse
23
alias__MODULE__
34

45
useEcto.Schema
56
importEcto.Changeset
67

7-
aliasGroupherServer.CMS.{
8+
aliasGroupherServer.{Accounts,CMS}
9+
10+
aliasCMS.{
811
Category,
912
Post,
1013
Video,
@@ -17,8 +20,6 @@ defmodule GroupherServer.CMS.Community do
1720
CommunityCheatsheet
1821
}
1922

20-
aliasGroupherServer.Accounts
21-
2223
@required_fields~w(title desc user_id logo raw)a
2324
# @required_fields ~w(title desc user_id)a
2425
@optional_fields~w(label geo_info index aka)a

‎lib/groupher_server/cms/community_category.ex‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@ defmodule GroupherServer.CMS.CommunityCategory do
44

55
useEcto.Schema
66
importEcto.Changeset
7-
aliasGroupherServer.CMS.{Category,Community}
7+
8+
aliasGroupherServer.CMS
9+
10+
aliasCMS.{Category,Community}
811

912
@typet::%CommunityCategory{}
1013

‎lib/groupher_server/cms/community_cheatsheet.ex‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@ defmodule GroupherServer.CMS.CommunityCheatsheet do
55
useEcto.Schema
66
importEcto.Changeset
77

8-
aliasGroupherServer.CMS.{Community,GithubContributor}
8+
aliasGroupherServer.CMS
9+
10+
aliasCMS.{Community,GithubContributor}
911

1012
@required_fields~w(community_id last_sync)a
1113
@optional_fields~w(readme)a

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp