foodb_objectbox_adapter
A new Flutter package project.
Getting Started
This project is a starting point for a Dart package, a library module containing code that can be shared easily across multiple Flutter or Dart projects.
For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.
Running unit test.
-
As this repo is using objectbox, it is very advisable to go through https://docs.objectbox.io/getting-started
-
You'll also need to run
bash <(curl -s https://raw.githubusercontent.com/objectbox/objectbox-dart/main/install.sh)
-
(MacOS) Manually create
lib
directory if you face this error. Chances are it created executablelib
file.ls: /usr/local/lib/*: Not a directory Error installing the library - not found
-
Create
temp
at the same level oflib
andtest
. -
Create
.env
at the same level oflib
andtest
. -
Define
COUCHDB_TEST_URI
variable in.env
with your own couchdb instance.
Running couch db with docker
- Docker images options:
- You might face lots of error when you view it in terminal. To resolve the errors, continue.
- Create directory to mount volume:
$ mkdir ~/data $ docker run -p 5984:5984 --volume ~/data:/opt/couchdb/data --env COUCHDB_USER=admin --env COUCHDB_PASSWORD=password apache/couchdb:2.1.1
- Update user
$ curl localhost:5984 {"couchdb":"Welcome","version":"2.1.1","features":["scheduler"],"vendor":{"name":"The Apache Software Foundation"}} $ curl -X PUT http://admin:password@localhost:5984/_users {"ok":true} $ curl -X PUT http://admin:password@localhost:5984/_replicator {"ok":true} $ curl -X PUT http://admin:password@localhost:5984/_global_changes {"ok":true}
- Update
COUCHDB_TEST_URI
toCOUCHDB_TEST_URI=http://admin:password@localhost:5984
.