mirror of
https://github.com/fnproject/fn.git
synced 2022-10-28 21:29:17 +03:00
Teach fn build --no-cache to avoid using cached steps
This commit is contained in:
committed by
James Jeffrey
parent
0b736b4b1c
commit
c734efefce
@@ -20,6 +20,7 @@ func build() cli.Command {
|
||||
|
||||
type buildcmd struct {
|
||||
verbose bool
|
||||
noCache bool
|
||||
}
|
||||
|
||||
func (b *buildcmd) flags() []cli.Flag {
|
||||
@@ -29,6 +30,11 @@ func (b *buildcmd) flags() []cli.Flag {
|
||||
Usage: "verbose mode",
|
||||
Destination: &b.verbose,
|
||||
},
|
||||
cli.BoolFlag{
|
||||
Name: "no-cache",
|
||||
Usage: "Don't use docker cache",
|
||||
Destination: &b.noCache,
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
@@ -45,7 +51,7 @@ func (b *buildcmd) build(c *cli.Context) error {
|
||||
return err
|
||||
}
|
||||
|
||||
ff, err := buildfunc(verbwriter, fn)
|
||||
ff, err := buildfunc(verbwriter, fn, b.noCache)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user