strings.Replace(t.Format(time.RFC3339), "T0", "T", 1)
?

christoph...@gmail.com a következőt írta (2022. április 25., hétfő, 
18:10:45 UTC+2):

> I need to format a time stamp hours in 24h format but without leading 0. 
> This means 7 -> "7" and 17 -> "17".
>
> For 24h values, the only formatting key value provided and documented is 
> 15. But this produces "7" -> "07" and 17 -> "17" which is not what I need.
>
> According to  https://gosamples.dev/date-time-format-cheatsheet/, a 
> formatting key word for this format seam to be missing. 
>
> Note by the way that the formatting key value numbering is easy to 
> remember for Americans only. Every time I need to format a time value I 
> have to look it up with google, or the cheat sheet referenced above.
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/2075ef73-19fd-4ad4-b4a6-0910bf348cb6n%40googlegroups.com.

Reply via email to