@beauraines/sprint-tracker 0.6.4 → 0.6.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/publish.yml +1 -1
- package/.github/workflows/test.yaml +1 -1
- package/CHANGELOG.md +7 -0
- package/R/sprintOutcomesCli.R +3 -3
- package/README.md +11 -4
- package/cmds/visualizations.js +7 -6
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [0.6.5](https://bitbucket.org/beauraines/sprint-tracker/compare/v0.6.4...v0.6.5) (2023-12-13)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* depends on local R ([#46](https://bitbucket.org/beauraines/sprint-tracker/issues/46)) ([1e8bf5e](https://bitbucket.org/beauraines/sprint-tracker/commit/1e8bf5ed534f52e569bab60cf501826b0f9b06f6))
|
|
11
|
+
|
|
5
12
|
### [0.6.4](https://bitbucket.org/beauraines/sprint-tracker/compare/v0.6.3...v0.6.4) (2023-12-07)
|
|
6
13
|
|
|
7
14
|
|
package/R/sprintOutcomesCli.R
CHANGED
|
@@ -3,7 +3,7 @@ library(ggplot2)
|
|
|
3
3
|
|
|
4
4
|
# sqlite3 --header --csv tracker.db < sql/sprintOutcomes.sql > /tmp/outcomes.csv
|
|
5
5
|
|
|
6
|
-
outcomes = read_csv('
|
|
6
|
+
outcomes = read_csv('~/outcomes.csv')
|
|
7
7
|
|
|
8
8
|
outcomes <- outcomes %>%
|
|
9
9
|
tibble() %>%
|
|
@@ -98,6 +98,6 @@ plot<-ggplot(outcomes,
|
|
|
98
98
|
|
|
99
99
|
# plot # commented out for docker
|
|
100
100
|
|
|
101
|
-
ggsave(str_c("~/
|
|
101
|
+
ggsave(str_c("~/",str_replace(unique(outcomes$project_name)," ",""),"SprintOutcomesCli.png"),plot=plot,bg="white", width = 2882, height = 1700, units = "px")
|
|
102
102
|
|
|
103
|
-
print(str_c("Saving to ",str_c("~/
|
|
103
|
+
print(str_c("Saving to ",str_c("~/",str_replace(unique(outcomes$project_name)," ",""),"SprintOutcomesCli.png"),sep = " "))
|
package/README.md
CHANGED
|
@@ -40,15 +40,22 @@ Options:
|
|
|
40
40
|
```
|
|
41
41
|
## Dependencies
|
|
42
42
|
|
|
43
|
-
This CLI application relies on a local [sqlite](https://www.sqlite.org/download.html) database, [
|
|
43
|
+
This CLI application relies on a local [sqlite](https://www.sqlite.org/download.html) database, [R](https://cran.r-project.org/) including [tidyverse](https://tidyverse.tidyverse.org/) to function. Installation of these dependencies is outside of the scope of this project as the steps vary by OS.
|
|
44
44
|
|
|
45
45
|
On Mac, these can be installed with homebrew.
|
|
46
46
|
|
|
47
47
|
```bash
|
|
48
|
-
brew install
|
|
49
|
-
docker pull rocker/tidyverse
|
|
48
|
+
brew install sqlite r
|
|
50
49
|
```
|
|
51
50
|
|
|
51
|
+
Install the tidyverse packages
|
|
52
|
+
|
|
53
|
+
1. Start R with the `R` command
|
|
54
|
+
2. Install tidyverse `install.packages("tidyverse")`
|
|
55
|
+
3. Pick a close mirror from the list provided
|
|
56
|
+
4. A very long compile process will run, approximately 20 minutes depending upon your hardware.
|
|
57
|
+
5. Once it is installed quit R with `q()` and respond to the prompts to **not** save your workspace.
|
|
58
|
+
|
|
52
59
|
## Installation Instructions
|
|
53
60
|
|
|
54
61
|
The sprint-tracker can be installed with `npm -g i @beauraines/sprint-tracker` to be used locally. Once you've installed it, follow the [General Usage](#general-usage) instructions. If you're going to contribute to the package, see [Installation and Setup for Development](#installation-and-setup-for-development).
|
|
@@ -61,7 +68,7 @@ The sprint-tracker can be installed with `npm -g i @beauraines/sprint-tracker` t
|
|
|
61
68
|
8. Run `sprint-tracker addProject` to add a project to the database. This step can be repeated as new projects are started.
|
|
62
69
|
9. Add the first sprint with `sprint-tracker addSprint` optionally, adding the sprint commitment. This step can be repeated for subsequent sprints.
|
|
63
70
|
10. At the end of the sprint, record sprint outcomes `sprint-tracker addOutcome`. This will allow you to log information about stories and points completed, committed, pulled forward, carried over, and bugs.
|
|
64
|
-
11. Generate the cumulative sprint outcomes visualization with `sprint-tracker visualizations`.
|
|
71
|
+
11. Generate the cumulative sprint outcomes visualization with `sprint-tracker visualizations`.
|
|
65
72
|
|
|
66
73
|
|
|
67
74
|
## Configuration
|
package/cmds/visualizations.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
const { AsyncParser } = require('@json2csv/node')
|
|
4
|
-
const {homedir
|
|
4
|
+
const { homedir } = require('os');
|
|
5
5
|
const { database: db } = require('helpers')
|
|
6
6
|
const { prompt } = require('../utils/input.js')
|
|
7
7
|
const {readConfig} = require('helpers').config
|
|
@@ -82,7 +82,7 @@ const handler = async function () {
|
|
|
82
82
|
// Write to file
|
|
83
83
|
|
|
84
84
|
|
|
85
|
-
const outputFile = path.join(
|
|
85
|
+
const outputFile = path.join(homedir(),'outcomes.csv');
|
|
86
86
|
try {
|
|
87
87
|
fs.writeFileSync(outputFile, csv);
|
|
88
88
|
// file written successfully
|
|
@@ -94,10 +94,11 @@ const handler = async function () {
|
|
|
94
94
|
|
|
95
95
|
|
|
96
96
|
console.log('Making visualizations')
|
|
97
|
-
// Run docker command
|
|
98
|
-
let PROJECT_DIR=path.join(homedir(),'projects')
|
|
99
|
-
let IMAGE='rocker/tidyverse'
|
|
100
|
-
const cmd = `docker run -t --rm -v ${PROJECT_DIR}:/home/rstudio/projects/ -v ${tmpdir()}:/tmp ${IMAGE} su -c 'Rscript /home/rstudio/projects/sprint-tracker/R/sprintOutcomesCli.R' rstudio`
|
|
97
|
+
// // Run docker command
|
|
98
|
+
// let PROJECT_DIR=path.join(homedir(),'projects')
|
|
99
|
+
// let IMAGE='rocker/tidyverse'
|
|
100
|
+
// const cmd = `docker run -t --rm -v ${PROJECT_DIR}:/home/rstudio/projects/ -v ${tmpdir()}:/tmp ${IMAGE} su -c 'Rscript /home/rstudio/projects/sprint-tracker/R/sprintOutcomesCli.R' rstudio`
|
|
101
|
+
const cmd = `Rscript ${__dirname}/../R/sprintOutcomesCli.R`
|
|
101
102
|
exec(cmd, function(err, stdout, stderr) {
|
|
102
103
|
if (err) {
|
|
103
104
|
console.log(stderr);
|