Skip to content

Commit cff180b

Browse files
Merge pull request #1 from tanveerisonline/greetings-backend
Greetings backend
2 parents 7966669 + a3f75a2 commit cff180b

Some content is hidden

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

86 files changed

+1612
-1
lines changed

.gitattributes

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# See https://git-scm.com/docs/gitattributes for more about git attribute files.
2+
3+
# Mark the database schema as having been generated.
4+
db/schema.rb linguist-generated
5+
6+
# Mark any vendored files as having been vendored.
7+
vendor/* linguist-vendored

.github/workflows/linters.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Linters
2+
3+
on: pull_request
4+
5+
env:
6+
FORCE_COLOR: 1
7+
8+
jobs:
9+
rubocop:
10+
name: Rubocop
11+
runs-on: ubuntu-22.04
12+
steps:
13+
- uses: actions/checkout@v3
14+
- uses: actions/setup-ruby@v1
15+
with:
16+
ruby-version: 3.1.x
17+
- name: Setup Rubocop
18+
run: |
19+
gem install --no-document rubocop -v '>= 1.0, < 2.0' # https://docs.rubocop.org/en/stable/installation/
20+
[ -f .rubocop.yml ] || wget https://raw.githubusercontent.com/microverseinc/linters-config/master/ror/.rubocop.yml
21+
- name: Rubocop Report
22+
run: rubocop --color
23+
nodechecker:
24+
name: node_modules checker
25+
runs-on: ubuntu-22.04
26+
steps:
27+
- uses: actions/checkout@v3
28+
- name: Check node_modules existence
29+
run: |
30+
if [ -d "node_modules/" ]; then echo -e "\e[1;31mThe node_modules/ folder was pushed to the repo. Please remove it from the GitHub repository and try again."; echo -e "\e[1;32mYou can set up a .gitignore file with this folder included on it to prevent this from happening in the future." && exit 1; fi

.gitignore

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# See https://help.github.com/articles/ignoring-files for more about ignoring files.
2+
#
3+
# If you find yourself ignoring temporary files generated by your text editor
4+
# or operating system, you probably want to add a global ignore instead:
5+
# git config --global core.excludesfile '~/.gitignore_global'
6+
7+
# Ignore bundler config.
8+
/.bundle
9+
10+
# Ignore all logfiles and tempfiles.
11+
/log/*
12+
/tmp/*
13+
!/log/.keep
14+
!/tmp/.keep
15+
16+
# Ignore pidfiles, but keep the directory.
17+
/tmp/pids/*
18+
!/tmp/pids/
19+
!/tmp/pids/.keep
20+
21+
# Ignore uploaded files in development.
22+
/storage/*
23+
!/storage/.keep
24+
/tmp/storage/*
25+
!/tmp/storage/
26+
!/tmp/storage/.keep
27+
28+
/public/assets
29+
30+
# Ignore master key for decrypting credentials and more.
31+
/config/master.key

.rubocop.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
AllCops:
2+
NewCops: enable
3+
Exclude:
4+
- 'db/**/*'
5+
- 'bin/*'
6+
- 'config/**/*'
7+
- 'Guardfile'
8+
- 'Rakefile'
9+
- 'node_modules/**/*'
10+
11+
DisplayCopNames: true
12+
13+
Layout/LineLength:
14+
Max: 120
15+
Metrics/MethodLength:
16+
Include:
17+
- 'app/controllers/*'
18+
- 'app/models/*'
19+
Max: 20
20+
Metrics/AbcSize:
21+
Include:
22+
- 'app/controllers/*'
23+
- 'app/models/*'
24+
Max: 50
25+
Metrics/ClassLength:
26+
Max: 150
27+
Metrics/BlockLength:
28+
AllowedMethods: ['describe']
29+
Max: 30
30+
31+
Style/Documentation:
32+
Enabled: false
33+
Style/ClassAndModuleChildren:
34+
Enabled: false
35+
Style/EachForSimpleLoop:
36+
Enabled: false
37+
Style/AndOr:
38+
Enabled: false
39+
Style/DefWithParentheses:
40+
Enabled: false
41+
Style/FrozenStringLiteralComment:
42+
EnforcedStyle: never
43+
44+
Layout/HashAlignment:
45+
EnforcedColonStyle: key
46+
Layout/ExtraSpacing:
47+
AllowForAlignment: false
48+
Layout/MultilineMethodCallIndentation:
49+
Enabled: true
50+
EnforcedStyle: indented
51+
Lint/RaiseException:
52+
Enabled: false
53+
Lint/StructNewOverride:
54+
Enabled: false
55+
Style/HashEachMethods:
56+
Enabled: false
57+
Style/HashTransformKeys:
58+
Enabled: false
59+
Style/HashTransformValues:
60+
Enabled: false

.ruby-version

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ruby-3.2.2

1.0

Whitespace-only changes.

Gemfile

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
source 'https://rubygems.org'
2+
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
3+
4+
ruby '3.2.2'
5+
6+
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
7+
gem 'rails', '~> 7.0.4', '>= 7.0.4.3'
8+
9+
gem 'rack-cors', require: 'rack/cors'
10+
11+
gem 'rubocop', '>= 1.0', '< 2.0'
12+
13+
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
14+
gem 'sprockets-rails'
15+
16+
# Use postgresql as the database for Active Record
17+
gem 'pg', '~> 1.1'
18+
19+
# Use the Puma web server [https://github.com/puma/puma]
20+
gem 'puma', '~> 5.0'
21+
22+
# Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails]
23+
gem 'importmap-rails'
24+
25+
# Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]
26+
gem 'turbo-rails'
27+
28+
# Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]
29+
gem 'stimulus-rails'
30+
31+
# Build JSON APIs with ease [https://github.com/rails/jbuilder]
32+
gem 'jbuilder'
33+
34+
# Use Redis adapter to run Action Cable in production
35+
# gem "redis", "~> 4.0"
36+
37+
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
38+
# gem "kredis"
39+
40+
# Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword]
41+
# gem "bcrypt", "~> 3.1.7"
42+
43+
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
44+
gem 'tzinfo-data', platforms: %i[mingw mswin x64_mingw jruby]
45+
46+
# Reduces boot times through caching; required in config/boot.rb
47+
gem 'bootsnap', require: false
48+
49+
# Use Sass to process CSS
50+
# gem "sassc-rails"
51+
52+
# Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images]
53+
# gem "image_processing", "~> 1.2"
54+
55+
group :development, :test do
56+
# See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
57+
gem 'debug', platforms: %i[mri mingw x64_mingw]
58+
end
59+
60+
group :development do
61+
# Use console on exceptions pages [https://github.com/rails/web-console]
62+
gem 'web-console'
63+
64+
# Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler]
65+
# gem "rack-mini-profiler"
66+
67+
# Speed up commands on slow machines / big apps [https://github.com/rails/spring]
68+
# gem "spring"
69+
end
70+
71+
group :test do
72+
# Use system testing [https://guides.rubyonrails.org/testing.html#system-testing]
73+
gem 'capybara'
74+
gem 'selenium-webdriver'
75+
gem 'webdrivers'
76+
end

0 commit comments

Comments
 (0)