File: setup.sh

package info (click to toggle)
ruby-dalli 5.0.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 992 kB
  • sloc: ruby: 9,447; sh: 19; makefile: 4
file content (32 lines) | stat: -rwxr-xr-x 999 bytes parent folder | download
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
#!/bin/bash
set -e

echo "Setting up Dalli development environment..."

# Install memcached using the script from scripts directory
echo "Installing memcached..."
cd /workspace
export MEMCACHED_VERSION=1.6.34
chmod +x scripts/install_memcached.sh
scripts/install_memcached.sh

# Clean up memcached installation files
echo "Cleaning up memcached installation files..."
rm -f memcached-${MEMCACHED_VERSION}.tar.gz
rm -rf memcached-${MEMCACHED_VERSION}

# Create symlink for memcached-tool if needed
if [ ! -f /usr/local/bin/memcached-tool ]; then
  echo "Creating symlink for memcached-tool..."
  sudo ln -sf /usr/share/memcached/scripts/memcached-tool /usr/local/bin/memcached-tool
fi

# Fix permissions
sudo chown -R vscode:vscode /usr/local/bundle
echo "Installing dependencies..."
cd /workspace
bundle install

echo "Environment setup complete!"
echo "You can now run tests with: bundle exec rake test"
echo "To run a specific test file: bundle exec ruby -Ilib:test test/integration/test_fork.rb"