Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision | |||
| docs:guide-developer:source-code:source-revision-calculation [2018/02/17 17:48] – ↷ Page moved from docs:guide-developer:source-revision-calculation to docs:guide-developer:source-code:source-revision-calculation bobafetthotmail | docs:guide-developer:source-code:source-revision-calculation [2018/03/18 18:22] (current) – [Convert between source revision and git commit hash] jeff | ||
|---|---|---|---|
| Line 8: | Line 8: | ||
| ===== Convert between source revision and git commit hash ===== | ===== Convert between source revision and git commit hash ===== | ||
| - | You can use ./ | + | You can use ./ |
| * Without arguments, it gives you current HEAD revision as " | * Without arguments, it gives you current HEAD revision as " | ||
| * If you give a version like " | * If you give a version like " | ||
| * If you give a git hash as argument, it calculates the rxxxx revision for it | * If you give a git hash as argument, it calculates the rxxxx revision for it | ||
| + | * If you give it its own output (" | ||
| === Example === | === Example === | ||
| Line 33: | Line 34: | ||
| $ ./ | $ ./ | ||
| 1bdd23231b9de6f98b5c51360167abc7b5e92716 | 1bdd23231b9de6f98b5c51360167abc7b5e92716 | ||
| + | </ | ||
| + | Recovering git commit from version string | ||
| + | < | ||
| + | lede_source$ git describe | ||
| + | v17.01.4-215-g05f0fac | ||
| + | |||
| + | lede_source$ ./ | ||
| + | r2993+783-b9a408c | ||
| + | |||
| + | lede_source$ ./ | ||
| + | 05f0fac189984981e3f28288e44d9afdd088dd77 | ||
| </ | </ | ||