例如,如果我使用Go创建了一个Web应用程序,我是否能够导入以下Go代码中列出的以下Git存储库:
package main
import (
"fmt"
"github.com/tealeg/xlsx"
)
func main() {
excelFileName := "/home/tealeg/foo.xlsx"
xlFile, err := xlsx.OpenFile(excelFileName)
if err != nil {
...
}
for _, sheet := range xlFile.Sheets {
for _, row := range sheet.Rows {
for _, cell := range row.Cells {
text, _ := cell.String()
fmt.Printf("%s\n", text)
}
}
}
}