Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workout names #8

Closed
mystygage opened this issue May 14, 2018 · 2 comments
Closed

workout names #8

mystygage opened this issue May 14, 2018 · 2 comments

Comments

@mystygage
Copy link
Contributor

mystygage commented May 14, 2018

Are there any restrictions for workout names?

This is my csv:

Week,Monday,Tuesday,Wednesday,Thursday,Friday,Saturday,Sunday
1,,"workout: 12k@GA1/2+STL
- run: 12km @z4
- cooldown: lap-button
- repeat: 3
 - run: 100m
 - recover: 1:00",,"workout: 10k@GA1/2+STL
- run: 10km @z4
- cooldown: lap-button
- repeat: 3
 - run: 100m
 - recover: 1:00","workout: 8k@GA1+STL
- run: 8km @z2
- cooldown: lap-button
- repeat: 3
 - run: 100m
 - recover: 1:00",,"workout: 10k@GA2
- run: 10 km @ z5
- cooldown: lap-button"
2,,"workout: 8k@GA1/2
- run: 8km @z4
- cooldown: lap-button","workout: 7x1k@GA2
- warmup: 2 km @ z2
- repeat: 3
 - run: 100 m
 - recover: 1:00
- repeat: 7
 - run: 1000 m @ z5
 - recover: 400 m
- recover: 2 km @ z2
- cooldown: lap-button",,"workout: 12k@GA1/2
- run: 12km @z4
- cooldown: lap-button",,"workout: 18k@GA1+STL
- run: 18 km @ z2
- cooldown: lap-button
- repeat: 3
 - run: 100 m
 - recover: 1:00"
3,,10k@GA2,12k@GA1/2+STL,,"workout: 6k@GA2
- run: 6 km @ z5
- cooldown: lap-button
- repeat: 3
 - run: 100 m
 - recover: 1:00",,"workout: 16k@GA1+STL
- run: 16 km @ z2
- cooldown: lap-button
- repeat: 3
 - run: 100 m
 - recover: 1:00"
4,,"workout: 12k@GA2
- run: 12 km @ z5
- cooldown: lap-button",8k@GA1/2+STL,,"workout: 8k@GA2
- run: 8 km @ z5
- cooldown: lap-button
- repeat: 3
 - run: 100 m
 - recover: 1:00",,"workout: 12k@GA1+STL
- run: 12 km @ z2
- cooldown: lap-button
- repeat: 3
 - run: 100 m
 - recover: 1:00"
5,,"workout: 5x1k@GA2
- warmup: 2 km @ z2
- repeat: 3
 - run: 100 m
 - recover: 1:00
- repeat: 5
 - run: 1000 m @ z5
 - recover: 400 m
- recover: 2 km @ z2
- cooldown: lap-button",,,"workout: 6k@GA1+STL
- run: 6 km @ z2
- cooldown: lap-button
- repeat: 3
 - run: 100 m
 - recover: 1:00",,"workout: HM
- run: 21.0975 km
- cooldown: lap-button"

This is the full log:

Successfully logged in to Garmin Connect

Deleting workouts:
  10k@GA2 -> [106094597]
  7x1k@GA2 -> [106094437]
  6k@GA2 -> [106094438]
  12k@GA2 -> [106094439]
  8k@GA2 -> [106094599]
  5x1k@GA2 -> [106094440]
  HM -> [106094600]

Creating workouts:
  10k@GA2
  7x1k@GA2
  6k@GA2
  12k@GA2
  8k@GA2
  5x1k@GA2
  HM

Scheduling:
  2018-05-20 -> 10k@GA2
  2018-05-23 -> 7x1k@GA2
  2018-05-29 -> 10k@GA2
  2018-06-01 -> 6k@GA2
  2018-06-05 -> 12k@GA2
  2018-06-08 -> 8k@GA2
  2018-06-12 -> 5x1k@GA2
  2018-06-17 -> HM

Statistics:
  7 deleted
  7 imported
  8 scheduled
Logged out and closed connection
Bye

All workouts with a + and / are silently skipped

@mystygage
Copy link
Contributor Author

private val WorkoutName = """^workout:\s([\w \-,;:\.@]+)((\n\s*\-\s[a-z]+:.*)*)$""".r

This regex doesn’t match workouts with + and / and therefore skips them... and some other not explicitly listed symbols. Are there any known problems with including more symbols?

@mgifos
Copy link
Owner

mgifos commented May 17, 2018

Yes, thanks for the feedback.
For now, I'll document what workout name can be and let the issue stay opened until I find some more time or if anyone offer help for this.

mgifos added a commit that referenced this issue May 29, 2018
mgifos added a commit that referenced this issue May 29, 2018
@mgifos mgifos closed this as completed May 29, 2018
@mgifos mgifos mentioned this issue May 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants