Giter Club home page Giter Club logo

neko-achievements's Introduction

RSpec CI

Contributing

Feel free to open tickets or send pull requests with improvements. Thanks in advance for your help!

Please follow the contribution guidelines.

Requirements

OSX or Linux

PostgreSQL >= 10.0, Ruby >= 2.6, NodeJS >= 10.0, Elasticsearch 6.x (7.0 not supported), Memcached, Redis

Issues Board (Agile Season)

https://agileseason.com/#/shared/board/098d2e36dff32f296d7815cf943ac8eb

Requirements

Checkout all projects

git clone [email protected]:shikimori/shikimori.git
git clone [email protected]:shikimori/neko-achievements.git
cd neko-achievements
mix local.hex --force
mix deps.get
cd ..
git clone [email protected]:shikimori/camo-server.git
cd camo-server
yarn
cd ..
git clone [email protected]:shikimori/faye-server.git
cd faye-server
yarn
cd ..
cd shikimori

Install yarn, tmux and overmind via Homebrew (OSX)

brew install yarn tmux overmind

In linux you have to install them another way.

Install dependent gems and npm packages

yarn install
bundle install

PostgreSQL

DB

psql -d postgres
create user shikimori_development;
create user shikimori_test;
alter user shikimori_development createdb;
alter user shikimori_test createdb;
alter user shikimori_development with superuser;
alter user shikimori_test with superuser;

Create databases

Make sure en_US.UTF-8 database collation is set https://gist.github.com/ffmike/877447#gistcomment-2851598

Or you manually initialize new database with command

initdb --pgdata=/usr/local/var/postgres-16 -E 'UTF-8' --lc-collate='en_US.UTF-8' --lc-ctype='en_US.UTF-8'

Or initdb for apple M1

initdb --pgdata=/usr/local/var/postgresql@16 -E 'UTF-8' --lc-collate='en_US.UTF-8' --lc-ctype='en_US.UTF-8'

Create rails databases

rails db:create

Local Run

Everything you need to run is listed in Procfile. Shikimori uses Overmind to execute Procfile.

Restore from a backup

rails db:drop && rails db:create
unzip -d db/ db/dump.sql.zip
psql -U shikimori_development -d shikimori_development -f db/dump.sql
rm db/dump.sql
RAILS_ENV=test rails db:schema:load
# migrate dump to latest schema
rails db:migrate

Start rails server

rails server

Start related services

overmind start

Start some of related services

OVERMIND_PROCESSES=camo,faye overmind start

Elasticsearch

In rails console:

Elasticsearch::RebuildIndexes.new.perform

Elasticsearch fix on OSX

Homebrew/homebrew-core#100260 (comment)

I've finally made it work, but I'm not sure this is the right call:

I've edited the service plist at /usr/local/Cellar/elasticsearch@6/6.8.23/[email protected]:

     <key>ProgramArguments</key>
     <array>
       <string>/usr/local/opt/elasticsearch@6/bin/elasticsearch</string>
     </array>
     <key>EnvironmentVariables</key>
     <dict>
+      <key>JAVA_HOME</key>
+      <string>'/usr/libexec/java_home -v 17'</string>
     </dict>
I had to edit the plist in the Cellar folder instead of the one in ~/Library/LaunchAgents because brew services is overwriting it at every start.

Update neko rules

rails neko:update

Other

Make a backup

pg_dump -c shikimori_development > db/dump.sql

Autorun rspec & rubocop

guard

Record apipie docs

APIPIE_RECORD=all rspec spec/controllers/api/**

Add new video hosting

# app/services/video_extractor/player_url_extractor.rb

Run locally in production mode

RAILS_ENV=production rails assets:precompile && IS_LOCAL_RUN=true RAILS_ENV=production rails server

Webpack debugger

https://nodejs.org/en/docs/inspector/ Install the Chrome Extension NIM (Node Inspector Manager): https://chrome.google.com/webstore/detail/nim-node-inspector-manage/gnhhdgbaldcilmgcpfddgdbkhjohddkj

RAILS_ENV=development NODE_ENV=development NODE_PATH=node_modules node --inspect-brk node_modules/.bin/webpack-dev-server --progress --color --config config/webpack/development.js

Shakapacker debugger

https://nodejs.org/en/docs/inspector/ Install the Chrome Extension NIM (Node Inspector Manager): https://chrome.google.com/webstore/detail/nim-node-inspector-manage/gnhhdgbaldcilmgcpfddgdbkhjohddkj

./bin/shakapacker-dev-server --debug-shakapacker

Webpack visualizer

https://chrisbateman.github.io/webpack-visualizer/

Dependabot

@dependabot ignore this dependency

neko-achievements's People

Contributors

4s1m0v avatar aniki-monfrere avatar baklazhanoviychai avatar boogiep0p avatar decursus avatar grin3671 avatar ignisdeuszero avatar imdanix avatar imoutochan avatar miladdv avatar momotarou1 avatar morr avatar rediskina avatar rozefound avatar severecloud avatar tap349 avatar tie avatar tristisoris avatar xmaid avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

neko-achievements's Issues

Повысить консистентность названий и описаний

Для общего стиля и исходя из смысла — точки в заголовках не нужны, а в описаниях нужны. Полно других моментов, которые стоит поправить, но этот меня парит достаточно сильно, чтобы провести большую часть работы.

Поэтому предлагаю следующие изменения:

Список аниме • Уровень 10

Сейчас Должно быть
It's not even the final form. It's not even the final form

Список аниме • Уровень 13
Учтите, что это четверостишие и то, что Раз, Два, Три и Четыре — имена котёнков.

Сейчас Должно быть
Раз котенок — самый белый Два котенок — самый смелый Три котенок — самый умный А четыре — самый шумный Раз — котенок самый белый, Два — котенок самый смелый, Три — котенок самый умный, А Четыре — самый шумный.
The first kitten is the whitest, The second kitten is the bravest The third kitten is the smartest And the fourth is the noisiest Kitten One is the whitest, Kitten Two is the bravest, Kitten Three is the smartest, Kitten Four is the noisiest.

Цундере • Уровень 1

Сейчас Должно быть
It's not what you think. It's not what you think

ГАР • Уровень 1

Сейчас Должно быть
So courageous that you can't breathe. So courageous that you can't breathe

Короткометражки • Уровень 1

Сейчас Должно быть
A moment, and you lost it. A moment, and you lost it

Махо-сёдзё • Уровень 4

Сейчас Должно быть
Your powers allow to change the universe Your powers allow to change the universe.

Меха • Уровень 1

Сейчас Должно быть
Get In The Freaking Robot Shinji Get in the freaking robot, Shinji!

Меха • Уровень 4
На обоих языках.

Сейчас Должно быть
ORE WA GUNDAM ORE WA GUNDAM!

Повседневность • Уровень 1

Сейчас Должно быть
The average Japanese schoolboy (or schoolgirl). The average Japanese student

Военное • Уровень 1

Сейчас Должно быть
Enlisted in the regular draft Enlisted in the regular draft.

Полиция • Уровень 1

Сейчас Должно быть
The streets are turbulent. Can't let our guard down The streets are turbulent. Can't let our guard down.

Космос • Уровень 1

Сейчас Должно быть
That's one small step for man, one giant leap for mankind That's one small step for man, one giant leap for mankind.

Музыка • Уровень 2

Сейчас Должно быть
Where words are powerless. Where words are powerless

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.