Files
ent/entc/gen/template/import.tmpl
Ariel Mashraki e0e754717e ent: change ent package name (#1338)
Summary:
Pull Request resolved: https://github.com/facebookexternal/fbc/pull/1338

Pull Request resolved: https://github.com/facebookincubator/ent/pull/14

Reviewed By: alexsn

Differential Revision: D16890825

fbshipit-source-id: 656baaa73f5debab08c849b6b9639caeec2a8ef1
2019-08-19 09:32:14 -07:00

27 lines
556 B
Cheetah

{{ define "import" }}
import (
"fmt"
"context"
"errors"
"math"
"strconv"
"strings"
"time"
{{/* ignore generting on graph templates */}}
{{ if not (eq $.Config.Package $.Package) }}
"{{ $.Config.Package }}/predicate"
"{{ $.Config.Package }}/{{ $.Package }}"
{{ with $.Config.Schema }} "{{ . }}" {{ end }}
{{ end }}
"github.com/facebookincubator/ent"
"github.com/facebookincubator/ent/dialect"
{{ range $_, $storage := $.Storage -}}
{{ range $_, $import := $storage.Imports -}}
"{{ $import }}"
{{ end -}}
{{ end -}}
)
{{ end }}