chore: file header and change local text

This commit is contained in:
tiglog 2023-08-21 17:42:50 +08:00
parent 0cc0b5f310
commit d74d4a5348
21 changed files with 206 additions and 56 deletions

View File

@ -1,3 +1,10 @@
//
// config.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import "git.hexq.cn/tiglog/golib/helper/text" import "git.hexq.cn/tiglog/golib/helper/text"

View File

@ -1,3 +1,10 @@
//
// render.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,9 +1,16 @@
//
// render_bidi_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (
"testing" "testing"
"github.com/jedib0t/go-pretty/v6/text" "git.hexq.cn/tiglog/golib/helper/text"
) )
func TestTable_Render_BiDiText(t *testing.T) { func TestTable_Render_BiDiText(t *testing.T) {

View File

@ -1,3 +1,10 @@
//
// render_csv.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (
@ -7,6 +14,7 @@ import (
) )
// RenderCSV renders the Table in CSV format. Example: // RenderCSV renders the Table in CSV format. Example:
//
// #,First Name,Last Name,Salary, // #,First Name,Last Name,Salary,
// 1,Arya,Stark,3000, // 1,Arya,Stark,3000,
// 20,Jon,Snow,2000,"You know nothing\, Jon Snow!" // 20,Jon,Snow,2000,"You know nothing\, Jon Snow!"

View File

@ -1,3 +1,10 @@
//
// render_csv_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// render_hint.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
// renderHint has hints for the Render*() logic // renderHint has hints for the Render*() logic

View File

@ -1,3 +1,10 @@
//
// render_html.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (
@ -13,6 +20,7 @@ const (
) )
// RenderHTML renders the Table in HTML format. Example: // RenderHTML renders the Table in HTML format. Example:
//
// <table class="go-pretty-table"> // <table class="go-pretty-table">
// <thead> // <thead>
// <tr> // <tr>

View File

@ -1,10 +1,17 @@
//
// render_html_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (
"fmt" "fmt"
"testing" "testing"
"github.com/jedib0t/go-pretty/v6/text" "git.hexq.cn/tiglog/golib/helper/text"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View File

@ -1,3 +1,10 @@
//
// render_init.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// render_markdown.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (
@ -6,6 +13,7 @@ import (
) )
// RenderMarkdown renders the Table in Markdown format. Example: // RenderMarkdown renders the Table in Markdown format. Example:
//
// | # | First Name | Last Name | Salary | | // | # | First Name | Last Name | Salary | |
// | ---:| --- | --- | ---:| --- | // | ---:| --- | --- | ---:| --- |
// | 1 | Arya | Stark | 3000 | | // | 1 | Arya | Stark | 3000 | |

View File

@ -1,3 +1,10 @@
//
// render_markdown_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// render_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// sort.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// sort_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// style.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import "git.hexq.cn/tiglog/golib/helper/text" import "git.hexq.cn/tiglog/golib/helper/text"

View File

@ -1,3 +1,10 @@
//
// table.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// table_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// util.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// util_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// writer.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (

View File

@ -1,3 +1,10 @@
//
// writer_test.go
// Copyright (C) 2023 tiglog <me@tiglog.com>
//
// Distributed under terms of the MIT license.
//
package table package table
import ( import (