Skip to content

Commit 5b026a5

Browse files
docs(setup): enhance setup instructions for clarity and consistency across platforms
1 parent 3a832bd commit 5b026a5

File tree

1 file changed

+53
-21
lines changed

1 file changed

+53
-21
lines changed

README.md

Lines changed: 53 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -38,55 +38,62 @@ Requirements
3838

3939
Initial setup (Windows + XAMPP + PowerShell)
4040

41+
Or, on Unix-like systems (macOS / Linux with bash): examples are provided below where relevant.
42+
4143
1. Clone the repository:
4244

43-
```powershell
45+
```bash
4446
git clone https://github.com/Barata-Ribeiro/MediManage.git
4547
cd MediManage
4648
```
4749

48-
2. Install PHP dependencies with Composer:
50+
2. Install PHP & Node dependencies
4951

50-
```powershell
51-
composer install
52+
```bash
53+
composer run setup
5254
```
5355

54-
3. Install Node dependencies and build assets:
55-
56-
```powershell
57-
npm install
58-
npm run dev
59-
```
56+
3. Configure environment
6057

61-
4. Environment file
58+
The command above already copies `.env.example` to `.env` and generates the application key. However, you may need to further edit `.env` to set database connection and other environment variables.
6259

63-
- Copy `.env.example` to `.env` and update values (DB settings, mailer, app key, etc.). On Windows PowerShell:
60+
The most important ones are:
6461

65-
```powershell
66-
Copy-Item .env.example .env
62+
```sh
63+
APP_NAME='YourAppName'
64+
APP_ADMIN_EMAIL='[email protected]'
65+
APP_ADMIN_NAME=Administrator
66+
APP_ADMIN_PASSWORD='123456A#'
67+
APP_ADMIN_FIRST_NAME='Sr. Admin'
68+
APP_ADMIN_LAST_NAME='of Site'
6769
```
6870

69-
- Generate the application key:
71+
If you plan to use MySQL instead of the default SQLite, update the DB\_\* variables accordingly; uncomment the relevant lines and provide your MySQL credentials.
7072

71-
```powershell
72-
php artisan key:generate
73-
```
73+
4. Database File (Optional)
7474

75-
- If you're using the default sqlite in `.env` (DB_CONNECTION=sqlite), create the database file:
75+
- If you're using the default sqlite in `.env` (`DB_CONNECTION=sqlite`), create the database file:
7676

7777
```powershell
78+
# Windows PowerShell
7879
New-Item -Path database\database.sqlite -ItemType File -Force
7980
```
8081

82+
```bash
83+
# macOS / Linux (bash)
84+
mkdir -p database
85+
touch database/database.sqlite
86+
```
87+
8188
5. Database migrations & seeders
8289

83-
```powershell
90+
```bash
8491
php artisan migrate --seed
8592
```
8693

8794
6. Start the local server (Laravel development server):
8895

89-
```powershell
96+
```bash
9097
composer run dev
9198
#SSR:
9299
composer run dev:ssr
@@ -133,9 +140,19 @@ Important files
133140

134141
Try it (quick start)
135142

143+
Option 1 — Full setup using the composer script (recommended):
144+
145+
```bash
146+
composer run setup
147+
```
148+
149+
Or manually, Option 2 — Manual setup:
150+
136151
1. Copy `.env` and set DB to sqlite (or configure MySQL). Create sqlite file if needed:
137152

138153
```powershell
154+
# Windows PowerShell
155+
composer install
139156
Copy-Item .env.example .env
140157
php artisan key:generate
141158
New-Item -Path database\database.sqlite -ItemType File -Force
@@ -145,6 +162,19 @@ npm run dev
145162
php artisan serve
146163
```
147164

165+
```bash
166+
# macOS / Linux (bash)
167+
composer install
168+
cp .env.example .env
169+
php artisan key:generate
170+
mkdir -p database
171+
touch database/database.sqlite
172+
php artisan migrate --seed
173+
npm install
174+
npm run dev
175+
php artisan serve
176+
```
177+
148178
2. Open http://127.0.0.1:8000 in your browser.
149179

150180
## 🪲 Bugs / ToDo
@@ -156,6 +186,8 @@ There are bugs and/or implementations that require some attention.
156186
- Implement route for notice deletion.
157187
- Implement route for contract creation.
158188
- Implement route for contract editing.
189+
- Implement delete functionality for roles.
190+
- Add delete confirmation modals for some actions.
159191

160192
## 🤝 Contributing
161193

0 commit comments

Comments
 (0)