Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* nom-order, part of the nom suite
- for more info see nom.ccallahan.info.
- Version 0.1 */
- package main
- import (
- "archive/tar"
- "io"
- "os"
- "log"
- )
- func var() (
- NOMHOME = os.Getenv("NOMHOME")
- )
- func init() {
- if NOMHOME == "" {
- log.Fatal("Yes, We can tell you never read the INSTALL guide.")
- }
- if PACKAGE == "" {
- log.Fatal("You need to specify that special package though the --package flag.")
- }
- flag.StringVar(&PACKAGE, "package", PACKAGE, "Package to deploy")
- }
- func main() {
- f, _ := os.Open(filepath.Join("PACKAGE.tar"))
- defer f.Close()
- untarred, _ := os.Create(filepath.Join(WATERHOME,PACKAGE))
- defer untarred.Close()
- tarReader := tar.NewReader(f)
- io.Copy(untarred, tarReader)
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement