Upgrade Readme
This commit is contained in:
@ -7,38 +7,12 @@
|
||||
```bash
|
||||
# Installer Go depuis les packages
|
||||
pkg install go
|
||||
|
||||
# Ou compiler depuis les ports
|
||||
cd /usr/ports/lang/go && make install clean
|
||||
pkg install npm
|
||||
pkg install node
|
||||
|
||||
# Vérifier l'installation
|
||||
go version
|
||||
```
|
||||
|
||||
## Clonage du projet
|
||||
|
||||
```bash
|
||||
# Cloner le repository
|
||||
git clone https://github.com/mathieu/project-notes.git
|
||||
cd project-notes
|
||||
|
||||
# Vérifier que tous les fichiers Go sont présents
|
||||
find . -name "*.go" | sort
|
||||
```
|
||||
|
||||
**Fichiers Go requis :**
|
||||
```
|
||||
./cmd/server/main.go # Point d'entrée principal
|
||||
./internal/api/daily_notes.go # Gestion des notes quotidiennes
|
||||
./internal/api/favorites.go # API des favoris
|
||||
./internal/api/handler.go # Handler HTTP principal
|
||||
./internal/api/handler_test.go # Tests unitaires
|
||||
./internal/api/rest_handler.go # API REST
|
||||
./internal/indexer/indexer.go # Indexation et recherche
|
||||
./internal/indexer/indexer_test.go # Tests indexeur
|
||||
./internal/watcher/watcher.go # Surveillance fichiers
|
||||
```
|
||||
|
||||
## Build
|
||||
|
||||
### 1. Télécharger les dépendances
|
||||
@ -56,6 +30,7 @@ go mod download
|
||||
|
||||
```bash
|
||||
go mod tidy
|
||||
go mod download
|
||||
```
|
||||
|
||||
**Note :** Si `go mod tidy` ne produit aucune sortie, c'est normal ! Cela signifie que le fichier `go.mod` est déjà à jour.
|
||||
@ -73,13 +48,6 @@ go build -ldflags="-s -w" -o server ./cmd/server
|
||||
CGO_ENABLED=0 go build -ldflags="-s -w" -o server ./cmd/server
|
||||
```
|
||||
|
||||
### 4. Vérifier le binaire
|
||||
|
||||
```bash
|
||||
file ./server
|
||||
./server --help
|
||||
```
|
||||
|
||||
## Lancement
|
||||
|
||||
### Mode développement
|
||||
|
||||
Reference in New Issue
Block a user