Skip to content

Instantly share code, notes, and snippets.

package main
import (
"encoding/json"
"fmt"
"github.com/go-playground/validator/v10"
)
func UnmarshalFoo(data []byte) (Foo, error) {
var r Foo
package main
import (
"encoding/json"
"fmt"
)
type Foo struct {
PropertyString string `json:"propString"`
PropertyMapString map[string]string `json:"propMapString"`
@ibraabada
ibraabada / json2map.go
Created February 27, 2020 10:45
json to map[string]string
package main
import (
"encoding/json"
"fmt"
)
func main() {
var j = `{
@ibraabada
ibraabada / GeniusMusixmatchLyricsFinder.applescript
Last active October 14, 2020 21:52
Genius x Musixmatch - Lyrics Finder
property my_title : "Ibra Itunes/Spotify Lyrics Search"
property baseURLGenius : "https://genius.com/search?q="
property baseURLMusicxmatch : "https://www.musixmatch.com/fr/search/"
tell application "Spotify"
set precNom to ""
repeat
if player state is not stopped then
set theTrack to current track
else if selection is not {} then