Skip to content

Commit

Permalink
Begin
Browse files Browse the repository at this point in the history
  • Loading branch information
KillianLucas committed Apr 9, 2024
1 parent 720e16a commit f3d7cde
Show file tree
Hide file tree
Showing 2 changed files with 100 additions and 0 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/up.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Cross-Platform Test

on: [push, pull_request]

jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- os: macos-10.15
script: ./unix.sh
- os: macos-11
script: ./unix.sh
- os: macos-12
script: ./unix.sh
- os: windows-2016
script: .\windows.ps1
- os: windows-2019
script: .\windows.ps1
- os: windows-2022
script: .\windows.ps1
- os: ubuntu-18.04
script: ./unix.sh
- os: ubuntu-20.04
script: ./unix.sh
- os: ubuntu-latest
script: ./unix.sh
# Using Docker for specific Linux distributions and versions
- os: ubuntu-latest
distro: debian:10
script: ./unix.sh
- os: ubuntu-latest
distro: debian:11
script: ./unix.sh
- os: ubuntu-latest
distro: centos:7
script: ./unix.sh
- os: ubuntu-latest
distro: centos:8
script: ./unix.sh

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v2

- name: Set up Docker container
if: matrix.distro
uses: addnab/docker-run-action@v2
with:
image: ${{ matrix.distro }}
options: -v ${{ github.workspace }}:/workspace
run: |
cd /workspace
${{ matrix.script }}
- name: Run script on macOS and Windows
if: matrix.os != 'ubuntu-latest' || matrix.distro == ''
run: ${{ matrix.script }}
shell: ${{ matrix.os == 'windows-latest' || matrix.os == 'windows-2019' || matrix.os == 'windows-2022' ? 'pwsh' : 'bash' }}
39 changes: 39 additions & 0 deletions unix.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
#!/bin/bash

echo "Starting Open Interpreter installation..."
sleep 2
echo "This will take approximately 5 minutes..."
sleep 2

# Define pyenv location
pyenv_root="$HOME/.pyenv/bin/pyenv"

# Check if pyenv is installed
if ! command -v $pyenv_root &> /dev/null
then
echo "pyenv is not installed. Installing now..."
curl https://pyenv.run | zsh #zsh is the default shell for mac now. Changing this may cause install to fail
else
echo "pyenv is already installed."
fi

PYENV_VERSION='3.11.7'

$pyenv_root init

$pyenv_root install $PYENV_VERSION --skip-existing

$pyenv_root init

$pyenv_root global $PYENV_VERSION

$pyenv_root exec pip install open-interpreter

$pyenv_root shell $PYENV_VERSION
$pyenv_root pip install open-interpreter
$pyenv_root shell --unset

echo ""
echo "Open Interpreter has been installed. Run the following command to use it: "
echo ""
echo "interpreter"

0 comments on commit f3d7cde

Please sign in to comment.