You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The DivBase server uses S3 buckets to store project files. Each project has its own assigned bucket. These buckets support versioning of files natively via S3. So individual files can be restored to prior versions if needed.
72
+
DivBase allows you to create named versions of your project's state at specific points in time. This is useful for tracking changes, ensuring reproducibility, and marking important milestones (e.g., when running analysis for a publication).
73
73
74
-
On top of this we also support versioning of the entire project's state via a special file stored in the bucket. This allows users to create named versions of the entire project at a given timepoint.
74
+
This means you can save the current state of your project as a named version, and later retrieve files as they were at that specific version (so you don't have to worry about having later updated files).
75
75
76
-
One potential use case for this could be:
76
+
### Add a new version
77
77
78
-
- Marking a time point when you did analysis for the a publication.
78
+
To save the current state of your project run:
79
79
80
-
At a later date, you could then download/upload all files from/to the bucket as they were at that timepoint to ensure reproducibility of results.
80
+
```bash
81
+
divbase-cli version add NAME [OPTIONS]
82
+
```
83
+
84
+
- Replace `NAME` with a unique name for the version (e.g., v1.0.0).
85
+
- You can optionally add a description using the --description flag.
86
+
87
+
**Note:** Versions are project wide, so you share them with all other members of the same project.
81
88
82
-
If you're in a new project, you can create the bucket versioning file by running
89
+
### Listing Versions
90
+
91
+
To see all existing versions of your project, run:
83
92
84
93
```bash
85
-
divbase-cli version create
94
+
divbase-cli version list
86
95
```
87
96
88
-
This will create a file in the bucket called `.bucket_versions.yaml`
97
+
This will display a list of all saved versions, including their names, descriptions, and creation dates.
98
+
99
+
### Specific Version Details
89
100
90
-
An already existing bucket likely has this file, we can see the contents of this file by running:
101
+
To get detailed information about a specific version, use:
91
102
92
103
```bash
93
-
divbase-cli version list
104
+
divbase-cli version info NAME
94
105
```
95
106
96
-
If after working with the bucket for a while you want to version the current state of the bucket, you can run:
107
+
This view will also include all the files associated with that version.
108
+
109
+
### Deleting Versions
110
+
111
+
To delete a specific version from your project, run:
97
112
98
113
```bash
99
-
divbase-cli version add [OPTIONS] NAME
114
+
divbase-cli version delete NAME
100
115
```
101
116
102
-
To download files from bucket at a specific bucket version/state, we can use the --bucket-version option and specify the version name we want to download from:
117
+
This will delete the version entry from the project. Deleted versions older than 30 days will be permanently deleted. You can ask a DivBase admin to restore a deleted version within that time period.
118
+
119
+
**NOTE:** The files associated with the version are never deleted by this operation.
120
+
121
+
### Downloading files from a specific version
122
+
123
+
To download files from your project as they were at a specific version, use the --project-version option:
0 commit comments