-
-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy pathsetup
More file actions
executable file
·37 lines (29 loc) · 1007 Bytes
/
setup
File metadata and controls
executable file
·37 lines (29 loc) · 1007 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/usr/bin/env bash
# frozen_string_literal: true
# Development environment setup script
set -e
echo "Setting up html2rss-web development environment..."
# Check if Ruby version is correct
ruby_version=$(ruby -v | cut -d' ' -f2 | cut -d'p' -f1)
echo "Ruby version: $ruby_version"
# Install dependencies
echo "Installing dependencies..."
bundle install
# Create .env file if it doesn't exist
if [ ! -f .env ]; then
echo "Creating .env file from .env.example..."
cp .env.example .env
echo "Please edit .env file with your configuration"
fi
# Create necessary directories
echo "Creating necessary directories..."
mkdir -p tmp/rack-cache-body
mkdir -p tmp/rack-cache-meta
# Run tests to verify setup
echo "Running tests to verify setup..."
bundle exec rspec
echo "Setup complete! You can now run:"
echo " bin/dev # Start development server (Ruby + Vite)"
echo " bin/dev-ruby # Start Ruby server only"
echo " bundle exec rspec # Run tests"
echo " bundle exec rubocop # Run linter"