diff options
author | Christian Pointner <equinox@helsinki.at> | 2016-09-02 02:17:41 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2016-09-02 02:17:41 (GMT) |
commit | 5f1a1745610f854d2c828439f164354e3ab8ffb6 (patch) | |
tree | a5f86a945cfd8dc5a19ad576da7543638b603e20 /rhimport/core.go | |
parent | 0d3025b170012a689793a42060bfdcc59843d057 (diff) |
youtube-dl fetches CBA api key from .netrc now
Diffstat (limited to 'rhimport/core.go')
-rw-r--r-- | rhimport/core.go | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/rhimport/core.go b/rhimport/core.go index 12ad35c..25a4090 100644 --- a/rhimport/core.go +++ b/rhimport/core.go @@ -25,13 +25,11 @@ package rhimport import ( - "bufio" "fmt" "io/ioutil" "log" "os" "path" - "strings" "code.helsinki.at/rhrd-go/rddb" "github.com/andelf/go-curl" @@ -47,8 +45,6 @@ const ( ARCHIV_HOST = "archiv.helsinki.at" ARCHIV_USER = "rhimport" ARCHIV_BASE_PATH = "/srv/archiv" - - CBA_API_KEY_FILE = "/etc/cba-api.key" ) var ( @@ -110,16 +106,6 @@ func (p *FilePolicy) FromString(str string) error { return nil } -func getCBAApiKey() string { - key_file, err := os.Open(CBA_API_KEY_FILE) - if err == nil { - defer key_file.Close() - data, _ := bufio.NewReader(key_file).ReadString('\n') - return strings.TrimSpace(string(data)) - } - return "" -} - type AttachmentChunk struct { Data []byte Error error |