exercism / exercism/cli

Link to community solutions after submitting when in Independent Mode

Abierto
#672 0 comentarios 1 reacción 0 asignados Ver en GitHub
Lenguaje dominante
Go
Estrellas
1.4k
Forks
363
Merge medio
6 d 13 h
PR fusionados (30 d)
2

Descripción

We should print the link for people to browse the community solutions if they're not in mentored mode.

At the bottom of the submit command, we can add something like this:

```diff
fmt.Fprintf(Out, " %s\n\n", solution.URL)
+
+ siteURL := config.InferSiteURL(usrCfg.GetString("apibaseurl"))
+ msg = `
+ View other solutions to this exercise at:
+ %s/tracks/%s/exercises/%s/solutions
+
+`
+ fmt.Fprintf(Err, msg, siteURL, solution.Track, solution.Exercise)
```

However, we will need to get the API to tell us which mode a solution is being solved in so that we can check for that before printing it, either as part of the solution metadata when downloading, or as part of the response when submitting. See also https://github.com/exercism/cli/issues/673

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.