mirror of
https://github.com/mudler/luet.git
synced 2025-09-02 07:45:02 +00:00
Add Separate tree for build dependency
Reuse the Recipe and extend it to read a separate tree for build dependencies. Also add accessors to compilespec to produce dockerfile image format.
This commit is contained in:
@@ -15,7 +15,10 @@
|
||||
|
||||
package helpers
|
||||
|
||||
import "os"
|
||||
import (
|
||||
"io/ioutil"
|
||||
"os"
|
||||
)
|
||||
|
||||
// Exists reports whether the named file or directory exists.
|
||||
func Exists(name string) bool {
|
||||
@@ -26,3 +29,11 @@ func Exists(name string) bool {
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
func Read(file string) (string, error) {
|
||||
dat, err := ioutil.ReadFile(file)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
return string(dat), nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user