Adjust import paths for hashicorp/hcl2 repo

This begins 'the great fork' of zcl to HCL.
This commit is contained in:
Martin Atkins 2017-09-11 15:38:42 -07:00
parent 523939034f
commit c3ca111fff
78 changed files with 103 additions and 103 deletions

View File

@ -9,9 +9,9 @@ import (
"os" "os"
"strings" "strings"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-zcl/zclparse" "github.com/hashicorp/hcl2/zclparse"
"github.com/zclconf/go-zcl/zclwrite" "github.com/hashicorp/hcl2/zclwrite"
"golang.org/x/crypto/ssh/terminal" "golang.org/x/crypto/ssh/terminal"
) )

View File

@ -4,8 +4,8 @@ import (
"path/filepath" "path/filepath"
"strings" "strings"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-zcl/zclparse" "github.com/hashicorp/hcl2/zclparse"
) )
// FileResolver creates and returns a Resolver that interprets include paths // FileResolver creates and returns a Resolver that interprets include paths

View File

@ -3,7 +3,7 @@ package include
import ( import (
"fmt" "fmt"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// MapResolver returns a Resolver that consults the given map for preloaded // MapResolver returns a Resolver that consults the given map for preloaded

View File

@ -1,7 +1,7 @@
package include package include
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// A Resolver maps an include path (an arbitrary string, but usually something // A Resolver maps an include path (an arbitrary string, but usually something

View File

@ -1,9 +1,9 @@
package include package include
import ( import (
"github.com/zclconf/go-zcl/ext/transform" "github.com/hashicorp/hcl2/ext/transform"
"github.com/zclconf/go-zcl/gozcl" "github.com/hashicorp/hcl2/gozcl"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Transformer builds a transformer that finds any "include" blocks in a body // Transformer builds a transformer that finds any "include" blocks in a body

View File

@ -5,10 +5,10 @@ import (
"testing" "testing"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/gozcl"
"github.com/hashicorp/hcl2/zcl"
"github.com/hashicorp/hcl2/zcltest"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/gozcl"
"github.com/zclconf/go-zcl/zcl"
"github.com/zclconf/go-zcl/zcltest"
) )
func TestTransformer(t *testing.T) { func TestTransformer(t *testing.T) {

View File

@ -1,7 +1,7 @@
package transform package transform
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// NewErrorBody returns a zcl.Body that returns the given diagnostics whenever // NewErrorBody returns a zcl.Body that returns the given diagnostics whenever

View File

@ -1,7 +1,7 @@
package transform package transform
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Shallow is equivalent to calling transformer.TransformBody(body), and // Shallow is equivalent to calling transformer.TransformBody(body), and

View File

@ -5,9 +5,9 @@ import (
"reflect" "reflect"
"github.com/hashicorp/hcl2/zcl"
"github.com/hashicorp/hcl2/zcltest"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
"github.com/zclconf/go-zcl/zcltest"
) )
// Assert that deepWrapper implements Body // Assert that deepWrapper implements Body

View File

@ -1,7 +1,7 @@
package transform package transform
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// A Transformer takes a given body, applies some (possibly no-op) // A Transformer takes a given body, applies some (possibly no-op)

View File

@ -1,10 +1,10 @@
package userfunc package userfunc
import ( import (
"github.com/hashicorp/hcl2/gozcl"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/function" "github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-zcl/gozcl"
"github.com/zclconf/go-zcl/zcl"
) )
var funcBodySchema = &zcl.BodySchema{ var funcBodySchema = &zcl.BodySchema{

View File

@ -4,9 +4,9 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/hashicorp/hcl2/zcl/zclsyntax"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
"github.com/zclconf/go-zcl/zcl/zclsyntax"
) )
func TestDecodeUserFunctions(t *testing.T) { func TestDecodeUserFunctions(t *testing.T) {

View File

@ -1,8 +1,8 @@
package userfunc package userfunc
import ( import (
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty/function" "github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-zcl/zcl"
) )
// A ContextFunc is a callback used to produce the base EvalContext for // A ContextFunc is a callback used to produce the base EvalContext for

View File

@ -4,9 +4,9 @@ import (
"fmt" "fmt"
"reflect" "reflect"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty/convert" "github.com/zclconf/go-cty/cty/convert"
"github.com/zclconf/go-cty/cty/gocty" "github.com/zclconf/go-cty/cty/gocty"
"github.com/zclconf/go-zcl/zcl"
) )
// DecodeBody extracts the configuration within the given body into the given // DecodeBody extracts the configuration within the given body into the given

View File

@ -6,10 +6,10 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
zclJSON "github.com/zclconf/go-zcl/zcl/json"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/zcl"
zclJSON "github.com/hashicorp/hcl2/zcl/json"
"github.com/zclconf/go-cty/cty"
) )
func TestDecodeBody(t *testing.T) { func TestDecodeBody(t *testing.T) {

View File

@ -6,7 +6,7 @@ import (
"sort" "sort"
"strings" "strings"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// ImpliedBodySchema produces a zcl.BodySchema derived from the type of the // ImpliedBodySchema produces a zcl.BodySchema derived from the type of the

View File

@ -5,8 +5,8 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/zclconf/go-zcl/zcl"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/zcl"
) )
func TestImpliedBodySchema(t *testing.T) { func TestImpliedBodySchema(t *testing.T) {

View File

@ -3,7 +3,7 @@ package gozcl
import ( import (
"reflect" "reflect"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
var victimExpr zcl.Expression var victimExpr zcl.Expression

View File

@ -3,9 +3,9 @@ package hclhil
import ( import (
"fmt" "fmt"
"github.com/zclconf/go-zcl/zcl"
"github.com/hashicorp/hcl" "github.com/hashicorp/hcl"
hclast "github.com/hashicorp/hcl/hcl/ast" hclast "github.com/hashicorp/hcl/hcl/ast"
"github.com/hashicorp/hcl2/zcl"
) )
func parse(src []byte, filename string) (*zcl.File, zcl.Diagnostics) { func parse(src []byte, filename string) (*zcl.File, zcl.Diagnostics) {

View File

@ -5,7 +5,7 @@ import (
"io/ioutil" "io/ioutil"
"os" "os"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Parse attempts to parse the given buffer as HCL with HIL expressions and, // Parse attempts to parse the given buffer as HCL with HIL expressions and,

View File

@ -1,9 +1,9 @@
package hclhil package hclhil
import ( import (
"github.com/zclconf/go-zcl/zcl"
hclparser "github.com/hashicorp/hcl/hcl/parser" hclparser "github.com/hashicorp/hcl/hcl/parser"
hcltoken "github.com/hashicorp/hcl/hcl/token" hcltoken "github.com/hashicorp/hcl/hcl/token"
"github.com/hashicorp/hcl2/zcl"
hilast "github.com/hashicorp/hil/ast" hilast "github.com/hashicorp/hil/ast"
hilparser "github.com/hashicorp/hil/parser" hilparser "github.com/hashicorp/hil/parser"
) )

View File

@ -6,8 +6,8 @@ import (
hclast "github.com/hashicorp/hcl/hcl/ast" hclast "github.com/hashicorp/hcl/hcl/ast"
hcltoken "github.com/hashicorp/hcl/hcl/token" hcltoken "github.com/hashicorp/hcl/hcl/token"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
// body is our implementation of zcl.Body in terms of an HCL ObjectList // body is our implementation of zcl.Body in terms of an HCL ObjectList

View File

@ -8,8 +8,8 @@ import (
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
hclast "github.com/hashicorp/hcl/hcl/ast" hclast "github.com/hashicorp/hcl/hcl/ast"
hcltoken "github.com/hashicorp/hcl/hcl/token" hcltoken "github.com/hashicorp/hcl/hcl/token"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestBodyPartialContent(t *testing.T) { func TestBodyPartialContent(t *testing.T) {

View File

@ -5,11 +5,11 @@ import (
"strconv" "strconv"
"strings" "strings"
"github.com/zclconf/go-cty/cty" "github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-zcl/zcl"
"github.com/hashicorp/hil" "github.com/hashicorp/hil"
hilast "github.com/hashicorp/hil/ast" hilast "github.com/hashicorp/hil/ast"
"github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/function"
) )
func parseTemplate(src []byte, filename string, startPos zcl.Pos) (zcl.Expression, zcl.Diagnostics) { func parseTemplate(src []byte, filename string, startPos zcl.Pos) (zcl.Expression, zcl.Diagnostics) {

View File

@ -3,10 +3,10 @@ package hclhil
import ( import (
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/function" "github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-cty/cty/function/stdlib" "github.com/zclconf/go-cty/cty/function/stdlib"
"github.com/zclconf/go-zcl/zcl"
) )
func TestTemplateExpression(t *testing.T) { func TestTemplateExpression(t *testing.T) {

View File

@ -3,7 +3,7 @@ package json
import ( import (
"math/big" "math/big"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
type node interface { type node interface {

View File

@ -5,7 +5,7 @@ import (
"fmt" "fmt"
"math/big" "math/big"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
func parseFileContent(buf []byte, filename string) (node, zcl.Diagnostics) { func parseFileContent(buf []byte, filename string) (node, zcl.Diagnostics) {

View File

@ -5,8 +5,8 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/zclconf/go-zcl/zcl"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/zcl"
) )
func TestParse(t *testing.T) { func TestParse(t *testing.T) {

View File

@ -5,7 +5,7 @@ import (
"io/ioutil" "io/ioutil"
"os" "os"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Parse attempts to parse the given buffer as JSON and, if successful, returns // Parse attempts to parse the given buffer as JSON and, if successful, returns

View File

@ -3,8 +3,8 @@ package json
import ( import (
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestParse_nonObject(t *testing.T) { func TestParse_nonObject(t *testing.T) {

View File

@ -4,7 +4,7 @@ import (
"fmt" "fmt"
"github.com/apparentlymart/go-textseg/textseg" "github.com/apparentlymart/go-textseg/textseg"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
//go:generate stringer -type tokenType scanner.go //go:generate stringer -type tokenType scanner.go

View File

@ -6,7 +6,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
func TestScan(t *testing.T) { func TestScan(t *testing.T) {

View File

@ -3,10 +3,10 @@ package json
import ( import (
"fmt" "fmt"
"github.com/hashicorp/hcl2/zcl"
"github.com/hashicorp/hcl2/zcl/hclhil"
"github.com/hashicorp/hcl2/zcl/zclsyntax"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
"github.com/zclconf/go-zcl/zcl/hclhil"
"github.com/zclconf/go-zcl/zcl/zclsyntax"
) )
// body is the implementation of "Body" used for files processed with the JSON // body is the implementation of "Body" used for files processed with the JSON

View File

@ -6,7 +6,7 @@ import (
"testing" "testing"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
func TestBodyPartialContent(t *testing.T) { func TestBodyPartialContent(t *testing.T) {

View File

@ -3,10 +3,10 @@ package zclsyntax
import ( import (
"fmt" "fmt"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/convert" "github.com/zclconf/go-cty/cty/convert"
"github.com/zclconf/go-cty/cty/function" "github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-zcl/zcl"
) )
// Expression is the abstract type for nodes that behave as zcl expressions. // Expression is the abstract type for nodes that behave as zcl expressions.

View File

@ -3,11 +3,11 @@ package zclsyntax
import ( import (
"fmt" "fmt"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/convert" "github.com/zclconf/go-cty/cty/convert"
"github.com/zclconf/go-cty/cty/function" "github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-cty/cty/function/stdlib" "github.com/zclconf/go-cty/cty/function/stdlib"
"github.com/zclconf/go-zcl/zcl"
) )
type Operation struct { type Operation struct {

View File

@ -4,9 +4,9 @@ import (
"bytes" "bytes"
"fmt" "fmt"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/convert" "github.com/zclconf/go-cty/cty/convert"
"github.com/zclconf/go-zcl/zcl"
) )
type TemplateExpr struct { type TemplateExpr struct {

View File

@ -3,8 +3,8 @@ package zclsyntax
import ( import (
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestTemplateExprParseAndValue(t *testing.T) { func TestTemplateExprParseAndValue(t *testing.T) {

View File

@ -3,10 +3,10 @@ package zclsyntax
import ( import (
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/function" "github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-cty/cty/function/stdlib" "github.com/zclconf/go-cty/cty/function/stdlib"
"github.com/zclconf/go-zcl/zcl"
) )
func TestExpressionParseAndValue(t *testing.T) { func TestExpressionParseAndValue(t *testing.T) {

View File

@ -4,7 +4,7 @@ package zclsyntax
// Run 'go generate' on this package to update the set of functions here. // Run 'go generate' on this package to update the set of functions here.
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
func (e *AnonSymbolExpr) Variables() []zcl.Traversal { func (e *AnonSymbolExpr) Variables() []zcl.Traversal {

View File

@ -1,6 +1,6 @@
package zclsyntax package zclsyntax
import "github.com/zclconf/go-zcl/zcl" import "github.com/hashicorp/hcl2/zcl"
// File is the top-level object resulting from parsing a configuration file. // File is the top-level object resulting from parsing a configuration file.
type File struct { type File struct {

View File

@ -1,7 +1,7 @@
package zclsyntax package zclsyntax
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Node is the abstract type that every AST node implements. // Node is the abstract type that every AST node implements.

View File

@ -6,8 +6,8 @@ import (
"reflect" "reflect"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestParseTraversalAbs(t *testing.T) { func TestParseTraversalAbs(t *testing.T) {

View File

@ -6,9 +6,9 @@ import (
"fmt" "fmt"
"github.com/apparentlymart/go-textseg/textseg" "github.com/apparentlymart/go-textseg/textseg"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/convert" "github.com/zclconf/go-cty/cty/convert"
"github.com/zclconf/go-zcl/zcl"
) )
type parser struct { type parser struct {

View File

@ -5,8 +5,8 @@ import (
"strings" "strings"
"unicode" "unicode"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func (p *parser) ParseTemplate() (Expression, zcl.Diagnostics) { func (p *parser) ParseTemplate() (Expression, zcl.Diagnostics) {

View File

@ -5,9 +5,9 @@ import (
"testing" "testing"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/zcl"
"github.com/kylelemons/godebug/pretty" "github.com/kylelemons/godebug/pretty"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestParseConfig(t *testing.T) { func TestParseConfig(t *testing.T) {

View File

@ -1,8 +1,8 @@
package zclsyntax package zclsyntax
import ( import (
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
// ParseTraversalAbs parses an absolute traversal that is assumed to consume // ParseTraversalAbs parses an absolute traversal that is assumed to consume

View File

@ -1,7 +1,7 @@
package zclsyntax package zclsyntax
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
type peeker struct { type peeker struct {

View File

@ -1,7 +1,7 @@
package zclsyntax package zclsyntax
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// ParseConfig parses the given buffer as a whole zcl config file, returning // ParseConfig parses the given buffer as a whole zcl config file, returning

View File

@ -4,7 +4,7 @@ package zclsyntax
import ( import (
"bytes" "bytes"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// This file is generated from scan_tokens.rl. DO NOT EDIT. // This file is generated from scan_tokens.rl. DO NOT EDIT.

View File

@ -4,8 +4,8 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/kylelemons/godebug/pretty" "github.com/kylelemons/godebug/pretty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestScanTokens_normal(t *testing.T) { func TestScanTokens_normal(t *testing.T) {

View File

@ -4,7 +4,7 @@ import (
"fmt" "fmt"
"strings" "strings"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// AsZCLBlock returns the block data expressed as a *zcl.Block. // AsZCLBlock returns the block data expressed as a *zcl.Block.

View File

@ -5,9 +5,9 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/kylelemons/godebug/pretty" "github.com/kylelemons/godebug/pretty"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestBodyContent(t *testing.T) { func TestBodyContent(t *testing.T) {

View File

@ -4,7 +4,7 @@ import (
"fmt" "fmt"
"github.com/apparentlymart/go-textseg/textseg" "github.com/apparentlymart/go-textseg/textseg"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Token represents a sequence of bytes from some zcl code that has been // Token represents a sequence of bytes from some zcl code that has been

View File

@ -1,7 +1,7 @@
package zclsyntax package zclsyntax
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Variables returns all of the variables referenced within a given experssion. // Variables returns all of the variables referenced within a given experssion.

View File

@ -7,8 +7,8 @@ import (
"reflect" "reflect"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func TestVariables(t *testing.T) { func TestVariables(t *testing.T) {

View File

@ -1,7 +1,7 @@
package zclsyntax package zclsyntax
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// VisitFunc is the callback signature for VisitAll. // VisitFunc is the callback signature for VisitAll.

View File

@ -1,8 +1,8 @@
package zcldec package zcldec
import ( import (
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
func decode(body zcl.Body, block *zcl.Block, ctx *zcl.EvalContext, spec Spec, partial bool) (cty.Value, zcl.Body, zcl.Diagnostics) { func decode(body zcl.Body, block *zcl.Block, ctx *zcl.EvalContext, spec Spec, partial bool) (cty.Value, zcl.Body, zcl.Diagnostics) {

View File

@ -1,8 +1,8 @@
package zcldec package zcldec
import ( import (
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
// Decode interprets the given body using the given specification and returns // Decode interprets the given body using the given specification and returns

View File

@ -5,9 +5,9 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/hashicorp/hcl2/zcl/zclsyntax"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
"github.com/zclconf/go-zcl/zcl/zclsyntax"
) )
func TestDecode(t *testing.T) { func TestDecode(t *testing.T) {

View File

@ -1,7 +1,7 @@
package zcldec package zcldec
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// ImpliedSchema returns the *zcl.BodySchema implied by the given specification. // ImpliedSchema returns the *zcl.BodySchema implied by the given specification.

View File

@ -3,9 +3,9 @@ package zcldec
import ( import (
"fmt" "fmt"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/convert" "github.com/zclconf/go-cty/cty/convert"
"github.com/zclconf/go-zcl/zcl"
) )
// A Spec is a description of how to decode a zcl.Body to a cty.Value. // A Spec is a description of how to decode a zcl.Body to a cty.Value.

View File

@ -1,7 +1,7 @@
package zcldec package zcldec
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// Variables processes the given body with the given spec and returns a // Variables processes the given body with the given spec and returns a

View File

@ -5,8 +5,8 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
func TestVariables(t *testing.T) { func TestVariables(t *testing.T) {

View File

@ -1,7 +1,7 @@
package zcled package zcled
import ( import (
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
type contextStringer interface { type contextStringer interface {

View File

@ -4,10 +4,10 @@ import (
"fmt" "fmt"
"io/ioutil" "io/ioutil"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-zcl/zcl/hclhil" "github.com/hashicorp/hcl2/zcl/hclhil"
"github.com/zclconf/go-zcl/zcl/json" "github.com/hashicorp/hcl2/zcl/json"
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
// NOTE: This is the public interface for parsing. The actual parsers are // NOTE: This is the public interface for parsing. The actual parsers are

View File

@ -3,8 +3,8 @@ package zcltest
import ( import (
"fmt" "fmt"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
// MockBody returns a zcl.Body implementation that works in terms of a // MockBody returns a zcl.Body implementation that works in terms of a

View File

@ -5,8 +5,8 @@ import (
"reflect" "reflect"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
var mockBodyIsBody zcl.Body = mockBody{} var mockBodyIsBody zcl.Body = mockBody{}

View File

@ -4,8 +4,8 @@ import (
"bytes" "bytes"
"io" "io"
"github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-zcl/zcl"
) )
type Node interface { type Node interface {

View File

@ -6,8 +6,8 @@ import (
"testing" "testing"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
func TestBodyFindAttribute(t *testing.T) { func TestBodyFindAttribute(t *testing.T) {

View File

@ -1,7 +1,7 @@
package zclwrite package zclwrite
import ( import (
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
// placeholder token used when we don't have a token but we don't want // placeholder token used when we don't have a token but we don't want

View File

@ -7,7 +7,7 @@ import (
"reflect" "reflect"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
func TestFormat(t *testing.T) { func TestFormat(t *testing.T) {

View File

@ -1,7 +1,7 @@
package zclwrite package zclwrite
import ( import (
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
type nativeNodeSorter struct { type nativeNodeSorter struct {

View File

@ -3,8 +3,8 @@ package zclwrite
import ( import (
"sort" "sort"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
// Our "parser" here is actually not doing any parsing of its own. Instead, // Our "parser" here is actually not doing any parsing of its own. Instead,

View File

@ -6,9 +6,9 @@ import (
"testing" "testing"
"github.com/davecgh/go-spew/spew" "github.com/davecgh/go-spew/spew"
"github.com/hashicorp/hcl2/zcl"
"github.com/hashicorp/hcl2/zcl/zclsyntax"
"github.com/kylelemons/godebug/pretty" "github.com/kylelemons/godebug/pretty"
"github.com/zclconf/go-zcl/zcl"
"github.com/zclconf/go-zcl/zcl/zclsyntax"
) )
func TestParse(t *testing.T) { func TestParse(t *testing.T) {

View File

@ -3,7 +3,7 @@ package zclwrite
import ( import (
"bytes" "bytes"
"github.com/zclconf/go-zcl/zcl" "github.com/hashicorp/hcl2/zcl"
) )
// ParseConfig interprets the given source bytes into a *zclwrite.File. The // ParseConfig interprets the given source bytes into a *zclwrite.File. The

View File

@ -4,11 +4,11 @@ import (
"bytes" "bytes"
"testing" "testing"
"github.com/hashicorp/hcl2/zcl"
"github.com/hashicorp/hcl2/zcl/zclsyntax"
"github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty"
"github.com/zclconf/go-cty/cty/function" "github.com/zclconf/go-cty/cty/function"
"github.com/zclconf/go-cty/cty/function/stdlib" "github.com/zclconf/go-cty/cty/function/stdlib"
"github.com/zclconf/go-zcl/zcl"
"github.com/zclconf/go-zcl/zcl/zclsyntax"
) )
func TestRoundTripVerbatim(t *testing.T) { func TestRoundTripVerbatim(t *testing.T) {

View File

@ -5,7 +5,7 @@ import (
"io" "io"
"github.com/apparentlymart/go-textseg/textseg" "github.com/apparentlymart/go-textseg/textseg"
"github.com/zclconf/go-zcl/zcl/zclsyntax" "github.com/hashicorp/hcl2/zcl/zclsyntax"
) )
// TokenGen is an abstract type that can append tokens to a list. It is the // TokenGen is an abstract type that can append tokens to a list. It is the