Skip to content

The open alternative to Salesforce, designed for AI.

Fixs/reviews setups (#3067)

Varrooo0f7ddd2f14ac
diff --git a/packages/twenty-docs/docs/contributor/local-setup/yarn-setup.mdx b/packages/twenty-docs/docs/contributor/local-setup/yarn-setup.mdx
index 736ce06a58d..df1986565e1 100644
--- a/packages/twenty-docs/docs/contributor/local-setup/yarn-setup.mdx
+++ b/packages/twenty-docs/docs/contributor/local-setup/yarn-setup.mdx
@@ -154,7 +154,7 @@ You can access this using `twenty` postgres user (password: `twenty`)
</Tabs>
-## Step 3: Setup environment variables
+## Step 4: Setup environment variables
Twenty requires you to set some environment variables. Locally, you should set them through a `.env` file.
@@ -164,7 +164,7 @@ cp ./packages/twenty-front/.env.example ./packages/twenty-front/.env
cp ./packages/twenty-server/.env.example ./packages/twenty-server/.env
```
-## Step 4: Installing dependencies
+## Step 5: Installing dependencies
:::info
@@ -180,7 +180,7 @@ nvm use #recommended
yarn
```
-## Step 5: Running the project
+## Step 6: Running the project
Setup your database with the following command:
```bash
diff --git a/packages/twenty-postgres/linux/provision-postgres-linux.sh b/packages/twenty-postgres/linux/provision-postgres-linux.sh
index 14249c27406..39b77f57d40 100755
--- a/packages/twenty-postgres/linux/provision-postgres-linux.sh
+++ b/packages/twenty-postgres/linux/provision-postgres-linux.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
# Colors
RED=31
@@ -6,16 +6,16 @@ GREEN=32
BLUE=34
# Function to display colored output
-function echo_header {
+echo_header () {
COLOR=$1
MESSAGE=$2
- echo -e "\e[${COLOR}m\n=======================================================\e[0m"
- echo -e "\e[${COLOR}m${MESSAGE}\e[0m"
- echo -e "\e[${COLOR}m=======================================================\e[0m"
+ echo "\e[${COLOR}m\n=======================================================\e[0m"
+ echo "\e[${COLOR}m${MESSAGE}\e[0m"
+ echo "\e[${COLOR}m=======================================================\e[0m"
}
# Function to handle errors
-function handle_error {
+handle_error () {
echo_header $RED "Error: $1"
exit 1
}
@@ -75,5 +75,5 @@ fi
# Run the init.sql to setup database
echo_header $GREEN "Step [4/4]: Setting up database..."
-cp ./postgres/init.sql /tmp/init.sql
+cp ./init.sql /tmp/init.sql
sudo -u postgres psql -f /tmp/init.sql || handle_error "Failed to execute init.sql script."