scraper

command module
v0.5.2-beta Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 15, 2014 License: MIT Imports: 33 Imported by: 0

README

scraper

An auto-scraper for EmulationStation written in Go using hashes. This currently works with NES, SNES, GB, GBC, GBA, MD, SMS, 32X, GG, PCE, A2600 ROMs.

How it Works

The script works by crawling a directory of ROM files looking for known extensions. When it finds a file it hashes the ROM data minus any headers or special file formatting with the goal of hashing only the data pulled from the original game. It compares this hash to a DB I've compiled to look up the correct game in theGamesDB.net. It downloads the metadata and builds the gamelist.xml file.

Installation

Make sure you have go version 1.2 or later installed.

$ go version
go version go1.2.1 linux/amd64

Fetch and build.

$ go get github.com/sselph/scraper
$ go build github.com/sselph/scraper

Usage

$ cd <rom directory>
$ mkdir images
$ scraper

ROMs will be scanned and a gamelist.xml file will be created. All images will be placed inside the images folder.

Raspberry Pi

The Raspberry Pi's build process is a little different and I recommend building and running on a machine other than the PI. At the time of writing this raspbian has an old version of go 1.0.2 so it can't handle progressive scan jpeg files also when building for the pi you have to specificy the type of ARM processor.

Build:

$ GOARM=5 go build github.com/sselph/scraper

Usage: Add thumb_only so that it doesn't download the larger progressive jpeg files.

$ scraper -thumb_only

Used libraries

Package Description License
github.com/nfnt/resize resizes images ISC
github.com/kr/fs provides filesystem-related functions New BSD
github.com/mattn/go-sqlite3 provides sqlite MIT
github.com/mitchellh/go-homedir get user homedir MIT
github.com/syndtr/goleveldb provides leveldb Simplified BSD

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package gdb interacts with thegamedb.net's API.
Package gdb interacts with thegamedb.net's API.
rom
Package rom has helper functions for extracting rom data.
Package rom has helper functions for extracting rom data.
bin
gb
md
nes
Package nes decodes .nes files
Package nes decodes .nes files
pce
sms
snes
Package snes decodes .sms and .sfc files.
Package snes decodes .sms and .sfc files.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL