1.7 KiB
-
Implement a core package that will be in charge of file comparison, transfer
-
Implement protocol :
- Be careful about metadata, large files, error handling and performance
- Implement the sql version
- Implement the tls version
-
Create configuration file :
- server address
- sync mode
- sync interval
-
Enhanced error handling :
- Only use panic during uncoverable situations
- Use more explicit error types
-
Use json/yaml config format (see viper)
-
Authentication :
- Use a token based authentication system
- Use a secure way to store the token (KMS ?)
-
Maintain a data structure to track the synchronization state of files :
- Local status
- Remote status
- Synchronization status
-
See io/ioutil or io/fs to read/write files
-
Break functions into little functions
-
Use appropriate data structures to represent files and folders. Consider using a map to store file information for faster lookups.
-
Improve logging (using a library like logrus or zap) ?
-
Unit & integration tests
-
Improve code style
-
Document
// Gemini
-
Implement a CLI :
- Use a library like cobra or urfave/cli
-
Implement a GUI :
- Use a library like fltk or qt
-
Implement a web interface :
- Use a library like gin or echo
-
Implement a daemon :
- Use a library like daemon or godo
-
Implement a service :
- Use a library like consul or etcd
-
Implement a cloud storage integration :
- Use a library like aws-sdk-go or google-cloud-go
-
Implement a version control system integration :
- Use a library like git or mercurial
-
Implement a backup system integration :
- Use a library like restic or borg
-
Implement a file system watcher :
- Use a library like fsnotify or inotify