Skip to content

Commit

Permalink
Add api package (#16)
Browse files Browse the repository at this point in the history
Signed-off-by: Tamal Saha <[email protected]>
  • Loading branch information
tamalsaha authored Jan 11, 2021
1 parent 7d1b40e commit 779684d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion types.go → api/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/

package main
package api

type DocInfo struct {
Project ProjectInfo `json:"project"`
Expand Down
3 changes: 2 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (
"fmt"
"io"
"io/ioutil"
"kubepack.dev/chart-doc-gen/api"
"os"
"text/template"

Expand All @@ -46,7 +47,7 @@ func main() {
panic(err)
}
reader := y2.NewYAMLOrJSONDecoder(f, 2048)
var doc DocInfo
var doc api.DocInfo
err = reader.Decode(&doc)
if err != nil && err != io.EOF {
panic(err)
Expand Down

0 comments on commit 779684d

Please sign in to comment.