This commit is contained in:
Eduard Urbach 2018-04-08 11:10:58 +02:00
parent 5b77fa98cc
commit b0539f42a5
2 changed files with 0 additions and 49 deletions

View File

@ -1,25 +0,0 @@
package main
import (
"fmt"
"github.com/animenotifier/arn"
)
func main() {
defer arn.Node.Close()
for anime := range arn.StreamAnime() {
relations, _ := arn.GetAnimeRelations(anime.ID)
if relations == nil {
relations := &arn.AnimeRelations{
AnimeID: anime.ID,
Items: []*arn.AnimeRelation{},
}
arn.DB.Set("AnimeRelations", anime.ID, relations)
fmt.Println(anime.ID, anime.Title.Canonical)
}
}
}

View File

@ -1,24 +0,0 @@
package main
import (
"fmt"
"time"
"github.com/animenotifier/arn"
"github.com/fatih/color"
)
func main() {
color.Yellow("Adding kitsu/anime mappings")
defer color.Green("Finished")
defer arn.Node.Close()
for anime := range arn.StreamAnime() {
fmt.Println(anime.ID, anime)
anime.SetMapping("kitsu/anime", anime.ID)
anime.Save()
}
time.Sleep(time.Second)
}