Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
601e3567d7 | ||
|
|
13a45eb843 | ||
|
|
e0b7546408 | ||
|
|
1b719af25b | ||
|
|
8606cb53e0 | ||
|
|
7e1e31f87f | ||
|
|
8f2e99cccd | ||
|
|
a59d69ec3a | ||
|
|
f776e08b70 | ||
|
|
28797b6281 | ||
|
|
60585a6a50 | ||
|
|
6ebebf05d6 | ||
|
|
ba0f74c973 | ||
|
|
43b0e86ef2 | ||
|
|
3c630eb4e5 | ||
|
|
ffcaafbc27 | ||
|
|
7d58031d73 | ||
|
|
8f3981f6e0 | ||
|
|
31c6c7aa96 | ||
|
|
1a227b5054 | ||
|
|
b600103952 | ||
|
|
aa74d23907 | ||
|
|
0af9fd30e2 |
@@ -1,9 +1,17 @@
|
||||
#!/bin/bash
|
||||
|
||||
# build the binery
|
||||
go build
|
||||
|
||||
# Update HELP.md file
|
||||
echo -e "\`\`\`txt" > HELP.md
|
||||
go run . -? >> HELP.md
|
||||
./logo-ls -? >> HELP.md
|
||||
echo -e "\`\`\`" >> HELP.md
|
||||
exec git add HELP.md
|
||||
|
||||
# Update logo-ls.1.gz
|
||||
exec help2man -N -I logo-ls.h2m -o logo-ls.1 ./logo-ls
|
||||
exec gzip -f logo-ls.1
|
||||
exec git add logo-ls.1.gz
|
||||
|
||||
exit 0
|
||||
|
||||
@@ -1,43 +1,43 @@
|
||||
#!/bin/sh
|
||||
# #!/bin/sh
|
||||
|
||||
R_NAME=$1
|
||||
R_URL=$2
|
||||
# R_NAME=$1
|
||||
# R_URL=$2
|
||||
|
||||
error_exit()
|
||||
{
|
||||
if [ "$?" != "0" ]; then
|
||||
nl=$'\n'
|
||||
echo "$1""$nl""$2""$nl""$nl""Aborting push to ""$R_NAME"" (""$R_URL"")" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
# error_exit()
|
||||
# {
|
||||
# if [ "$?" != "0" ]; then
|
||||
# nl=$'\n'
|
||||
# echo "$1""$nl""$2""$nl""$nl""Aborting push to ""$R_NAME"" (""$R_URL"")" 1>&2
|
||||
# exit 1
|
||||
# fi
|
||||
# }
|
||||
|
||||
# Build binary for variety of arch
|
||||
# linux amd64
|
||||
ERROR=$(go env -w GOOS=linux GOARCH=amd64 2>&1 > /dev/null)
|
||||
error_exit "Cannot set GOOS=linux and GOARCH=amd64:" "$ERROR"
|
||||
ERROR=$(go build -o build/logo-ls-linux-amd64 2>&1 > /dev/null)
|
||||
error_exit "Cannot build logo-ls-linux-amd64:" "$ERROR"
|
||||
# # Build binary for variety of arch
|
||||
# # linux amd64
|
||||
# ERROR=$(go env -w GOOS=linux GOARCH=amd64 2>&1 > /dev/null)
|
||||
# error_exit "Cannot set GOOS=linux and GOARCH=amd64:" "$ERROR"
|
||||
# ERROR=$(go build -o build/logo-ls-linux-amd64 2>&1 > /dev/null)
|
||||
# error_exit "Cannot build logo-ls-linux-amd64:" "$ERROR"
|
||||
|
||||
# linux arm64
|
||||
ERROR=$(go env -w GOOS=linux GOARCH=arm64 2>&1 > /dev/null)
|
||||
error_exit "Cannot set GOOS=linux and GOARCH=arm64:" "$ERROR"
|
||||
ERROR=$(go build -o build/logo-ls-linux-arm64 2>&1 > /dev/null)
|
||||
error_exit "Cannot build logo-ls-linux-arm64:" "$ERROR"
|
||||
# # linux arm64
|
||||
# ERROR=$(go env -w GOOS=linux GOARCH=arm64 2>&1 > /dev/null)
|
||||
# error_exit "Cannot set GOOS=linux and GOARCH=arm64:" "$ERROR"
|
||||
# ERROR=$(go build -o build/logo-ls-linux-arm64 2>&1 > /dev/null)
|
||||
# error_exit "Cannot build logo-ls-linux-arm64:" "$ERROR"
|
||||
|
||||
# linux 386
|
||||
ERROR=$(go env -w GOOS=linux GOARCH=386 2>&1 > /dev/null)
|
||||
error_exit "Cannot set GOOS=linux and GOARCH=386:" "$ERROR"
|
||||
ERROR=$(go build -o build/logo-ls-linux-386 2>&1 > /dev/null)
|
||||
error_exit "Cannot build logo-ls-linux-386:" "$ERROR"
|
||||
# # linux 386
|
||||
# ERROR=$(go env -w GOOS=linux GOARCH=386 2>&1 > /dev/null)
|
||||
# error_exit "Cannot set GOOS=linux and GOARCH=386:" "$ERROR"
|
||||
# ERROR=$(go build -o build/logo-ls-linux-386 2>&1 > /dev/null)
|
||||
# error_exit "Cannot build logo-ls-linux-386:" "$ERROR"
|
||||
|
||||
# darwin amd64
|
||||
ERROR=$(go env -w GOOS=darwin GOARCH=amd64 2>&1 > /dev/null)
|
||||
error_exit "Cannot set GOOS=darwin and GOARCH=amd64:" "$ERROR"
|
||||
ERROR=$(go build -o build/logo-ls-darwin-amd64 2>&1 > /dev/null)
|
||||
error_exit "Cannot build logo-ls-darwin-amd64:" "$ERROR"
|
||||
# # darwin amd64
|
||||
# ERROR=$(go env -w GOOS=darwin GOARCH=amd64 2>&1 > /dev/null)
|
||||
# error_exit "Cannot set GOOS=darwin and GOARCH=amd64:" "$ERROR"
|
||||
# ERROR=$(go build -o build/logo-ls-darwin-amd64 2>&1 > /dev/null)
|
||||
# error_exit "Cannot build logo-ls-darwin-amd64:" "$ERROR"
|
||||
|
||||
# reset env to default
|
||||
go env -u GOOS GOARCH
|
||||
# # reset env to default
|
||||
# go env -u GOOS GOARCH
|
||||
|
||||
exit 0
|
||||
# exit 0
|
||||
|
||||
|
After Width: | Height: | Size: 532 KiB |
|
After Width: | Height: | Size: 411 KiB |
|
After Width: | Height: | Size: 71 KiB |
|
After Width: | Height: | Size: 57 KiB |
|
After Width: | Height: | Size: 44 KiB |
|
After Width: | Height: | Size: 55 KiB |
|
After Width: | Height: | Size: 200 KiB |
|
After Width: | Height: | Size: 172 KiB |
|
After Width: | Height: | Size: 36 KiB |
@@ -17,3 +17,10 @@
|
||||
# Do not commit the executable
|
||||
logo-ls
|
||||
build/
|
||||
|
||||
# distribution directory
|
||||
dist
|
||||
|
||||
# env stuff
|
||||
*.env
|
||||
.gh_token
|
||||
@@ -0,0 +1,101 @@
|
||||
# This is an example goreleaser.yaml file with some sane defaults.
|
||||
# Make sure to check the documentation at http://goreleaser.com
|
||||
|
||||
env_files:
|
||||
github_token: '{{ .Env.PWD }}.gh_token'
|
||||
|
||||
project_name: logo-ls
|
||||
|
||||
before:
|
||||
hooks:
|
||||
# You may remove this if you don't use go modules.
|
||||
- go mod download
|
||||
|
||||
builds:
|
||||
- env:
|
||||
- CGO_ENABLED=0
|
||||
# supported OS
|
||||
goos:
|
||||
- linux
|
||||
# - windows
|
||||
- darwin
|
||||
# supported ARCH
|
||||
goarch:
|
||||
- amd64
|
||||
- 386
|
||||
- arm64
|
||||
- arm
|
||||
# OS ARCH combinations to ignore
|
||||
ignore:
|
||||
- goos: darwin
|
||||
goarch: 386
|
||||
# Set the modified timestamp on the output binaries to the latest commit time.
|
||||
# Required for producing Reproducible builds
|
||||
mod_timestamp: '{{ .CommitTimestamp }}'
|
||||
|
||||
archives:
|
||||
- name_template: '{{ .ProjectName }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}'
|
||||
replacements:
|
||||
darwin: Darwin
|
||||
linux: Linux
|
||||
windows: Windows
|
||||
386: i386
|
||||
amd64: x86_64
|
||||
# override archiving [default tar.gz]
|
||||
format_overrides:
|
||||
- goos: windows
|
||||
format: zip
|
||||
# wrap the content of archive in a dir
|
||||
#so when extracting the content will be in a dir
|
||||
wrap_in_directory: true
|
||||
# files to be included in the archive + binary
|
||||
files:
|
||||
- LICENSE
|
||||
- HELP.md
|
||||
- logo-ls.1.gz
|
||||
# - CHANGELOG.md
|
||||
|
||||
checksum:
|
||||
name_template: '{{ .ProjectName }}_SHA512sums.txt'
|
||||
algorithm: sha512
|
||||
|
||||
signs:
|
||||
-
|
||||
cmd: gpg2
|
||||
# sign the checksum with Yash Handa (logo-ls) <yashhanda7@yahoo.com>
|
||||
args: ["-u", "0xD9498B225223344C0205FDF528182066BCACCCB2", "--output", "${signature}", "--detach-sign", "${artifact}"]
|
||||
artifacts: checksum
|
||||
|
||||
release:
|
||||
github:
|
||||
owner: Yash-Handa
|
||||
name: logo-ls
|
||||
|
||||
snapshot:
|
||||
name_template: "{{ .Tag }}-next"
|
||||
|
||||
changelog:
|
||||
sort: asc
|
||||
filters:
|
||||
exclude:
|
||||
- '^docs:'
|
||||
- '^test:'
|
||||
- '(?i)update Readme.md'
|
||||
|
||||
nfpms:
|
||||
-
|
||||
file_name_template: '{{ .ProjectName }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}'
|
||||
package_name: logo-ls
|
||||
homepage: https://github.com/Yash-Handa/logo-ls
|
||||
description: ls command with icons and git integration. Written in Golang
|
||||
maintainer: Yash Handa <yashhanda7@yahoo.com>
|
||||
license: MIT
|
||||
formats:
|
||||
- deb
|
||||
- rpm
|
||||
dependencies:
|
||||
- git
|
||||
recommends:
|
||||
- golang
|
||||
files:
|
||||
"logo-ls.1.gz": "/usr/share/man/man1/logo-ls.1.gz"
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"default": true,
|
||||
"MD033": false,
|
||||
"MD013": false
|
||||
}
|
||||
@@ -1,16 +1,16 @@
|
||||
```txt
|
||||
List information about the FILEs with ICONS and GIT STATUS (the current dir
|
||||
by default). Sort entries alphabetically if none of -tvSUX is specified.
|
||||
Usage: logo-ls [-1?aAcdDgGhiloRrSstUvVX] [-T value] [files ...]
|
||||
-1 list one file per line.
|
||||
-? display this help and exit
|
||||
-?, --help display this help and exit
|
||||
-a, --all do not ignore entries starting with .
|
||||
-A, --almost-all do not list implied . and ..
|
||||
-c, --disable-color
|
||||
don't color icons, filenames and git status (use this to
|
||||
print to a file)
|
||||
-d, --directory list directories themselves, not their contents
|
||||
-D, --disable-git-status
|
||||
don't print git status of files, In recursive -R this flag
|
||||
enables git-status
|
||||
-D, --git-status print git status of files
|
||||
-g like -l, but do not list owner
|
||||
-G, --no-group in a long listing, don't print group names
|
||||
-h, --human-readable
|
||||
@@ -19,8 +19,7 @@ Usage: logo-ls [-1?aAcdDgGhiloRrSstUvVX] [-T value] [files ...]
|
||||
don't print icons of the files
|
||||
-l use a long listing format
|
||||
-o like -l, but do not list group information
|
||||
-R, --recursive list subdirectories recursively, git-status is disabled by
|
||||
default
|
||||
-R, --recursive list subdirectories recursively
|
||||
-r, --reverse reverse order while sorting
|
||||
-S sort by file size, largest first
|
||||
-s, --size print the allocated size of each file, in blocks
|
||||
@@ -33,16 +32,21 @@ Usage: logo-ls [-1?aAcdDgGhiloRrSstUvVX] [-T value] [files ...]
|
||||
-X sort alphabetically by entry extension
|
||||
|
||||
Possible value for --time-style (-T)
|
||||
ANSIC "Mon Jan _2 15:04:05 2006"
|
||||
UnixDate "Mon Jan _2 15:04:05 MST 2006"
|
||||
RubyDate "Mon Jan 02 15:04:05 -0700 2006"
|
||||
RFC822 "02 Jan 06 15:04 MST"
|
||||
RFC822Z "02 Jan 06 15:04 -0700"
|
||||
RFC850 "Monday, 02-Jan-06 15:04:05 MST"
|
||||
RFC1123 "Mon, 02 Jan 2006 15:04:05 MST"
|
||||
RFC1123Z "Mon, 02 Jan 2006 15:04:05 -0700"
|
||||
RFC3339 "2006-01-02T15:04:05Z07:00"
|
||||
Kitchen "3:04PM"
|
||||
Stamp "Mon Jan _2 15:04:05" [Default]
|
||||
StampMilli "Jan _2 15:04:05.000"
|
||||
ANSIC "Mon Jan _2 15:04:05 2006"
|
||||
UnixDate "Mon Jan _2 15:04:05 MST 2006"
|
||||
RubyDate "Mon Jan 02 15:04:05 -0700 2006"
|
||||
RFC822 "02 Jan 06 15:04 MST"
|
||||
RFC822Z "02 Jan 06 15:04 -0700"
|
||||
RFC850 "Monday, 02-Jan-06 15:04:05 MST"
|
||||
RFC1123 "Mon, 02 Jan 2006 15:04:05 MST"
|
||||
RFC1123Z "Mon, 02 Jan 2006 15:04:05 -0700"
|
||||
RFC3339 "2006-01-02T15:04:05Z07:00"
|
||||
Kitchen "3:04PM"
|
||||
Stamp "Mon Jan _2 15:04:05" [Default]
|
||||
StampMilli "Jan _2 15:04:05.000"
|
||||
|
||||
Exit status:
|
||||
0 if OK,
|
||||
1 if minor problems (e.g., cannot access subdirectory),
|
||||
2 if serious trouble (e.g., cannot access command-line argument).
|
||||
```
|
||||
|
||||
@@ -1,5 +1,104 @@
|
||||

|
||||

|
||||

|
||||
|
||||
# logo-ls
|
||||
|
||||

|
||||

|
||||

|
||||
[](http://hits.dwyl.com/{Yash-Handa}/{logo-ls})
|
||||
|
||||
modern ls command with vscode like file logos. Written in Golang
|
||||
|
||||
Command and Arguments supported are listed in [HELP.md](/HELP.md)
|
||||
|
||||
## Check the downloaded Resource
|
||||
|
||||
receive public key of the signing party
|
||||
|
||||
```cmd
|
||||
$ gpg2 --keyid-format long --keyserver keyserver.ubuntu.com --recv-keys 0x28182066bcacccb2
|
||||
|
||||
gpg: key 28182066BCACCCB2: "Yash Handa (logo-ls) <yashhanda7@yahoo.com>" not changed
|
||||
gpg: Total number processed: 1
|
||||
gpg: unchanged: 1
|
||||
```
|
||||
|
||||
check the signature on logo-ls_SHA512sums.txt
|
||||
|
||||
```cmd
|
||||
$ gpg2 --keyid-format long --verify logo-ls_SHA512sums.txt.sig logo-ls_SHA512sums.txt
|
||||
|
||||
gpg: Signature made Tue 08 Sep 2020 10:21:52 PM IST
|
||||
gpg: using RSA key D9498B225223344C0205FDF528182066BCACCCB2
|
||||
gpg: Good signature from "Yash Handa (logo-ls) <yashhanda7@yahoo.com>" [ultimate]
|
||||
```
|
||||
|
||||
A **Good** signature means that the checked file was definitely signed by the owner of the keyfile stated (if they didn’t match, the signature would be reported as **BAD**)
|
||||
|
||||
Now use `logo-ls_SHA512sums.txt` file to verify the authenticity of the resource downloaded
|
||||
|
||||
```cmd
|
||||
$ sha512sum -c logo-ls_SHA512sums.txt 2>&1 | grep OK
|
||||
|
||||
logo-ls_Linux_x86_64.tar.gz: OK
|
||||
logo-ls_Linux_arm64.tar.gz: OK
|
||||
logo-ls_Darwin_x86_64.tar.gz: OK
|
||||
logo-ls_Linux_i386.tar.gz: OK
|
||||
logo-ls_Linux_armv6.tar.gz: OK
|
||||
```
|
||||
|
||||
Note: The downloaded resources to verify and `logo-ls_SHA512sums.txt` should be in the same directory
|
||||
|
||||
## Example Commands
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="logo-ls" title="logo-ls" src="/.github/images/ls.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="logo-ls -aD" title="logo-ls -aD" src="/.github/images/ls-aD.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="logo-ls -alhD" title="logo-ls -alhD" src="/.github/images/ls-alhD.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="logo-ls -1Dhs" title="logo-ls -1Dhs" src="/.github/images/ls-1Dhs.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="logo-ls -RD" title="logo-ls -RD" src="/.github/images/ls-RD.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="logo-ls -a" title="logo-ls -a" src="/.github/images/ls-a.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="logo-ls -oahd -T Kitchen" title="logo-ls -oahd -T Kitchen" src="/.github/images/ls-oahD.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
## Icon Set
|
||||
|
||||
<div>
|
||||
<span align="center">
|
||||
<img alt="icons" title="Icon Set" src="/.github/images/icons.png">
|
||||
</span>
|
||||
</div><br>
|
||||
|
||||
@@ -163,14 +163,14 @@ func (w *CTW) colW(b, e int) [4]int {
|
||||
|
||||
func (w *CTW) printCell(buf *bytes.Buffer, i int, cs [4]int) {
|
||||
if cs[0] > 0 {
|
||||
fmt.Fprintf(buf, "%-*s ", cs[0]-1, w.d[i][0])
|
||||
fmt.Fprintf(buf, "%-*s%s", cs[0]-1, w.d[i][0], brailEmpty)
|
||||
}
|
||||
if w.showIcon {
|
||||
fmt.Fprintf(buf, "%s%1s%s ", w.ic[i], w.d[i][1], white)
|
||||
fmt.Fprintf(buf, "%s%1s%s%s", w.ic[i], w.d[i][1], white, brailEmpty)
|
||||
}
|
||||
fmt.Fprintf(buf, "%s%-*s%s", getGitColor(w.d[i][3]), cs[2], w.d[i][2], white)
|
||||
|
||||
if cs[3] > 0 {
|
||||
fmt.Fprintf(buf, " %s%1s%s", getGitColor(w.d[i][3]), w.d[i][3], white)
|
||||
fmt.Fprintf(buf, "%s%s%1s%s", brailEmpty, getGitColor(w.d[i][3]), w.d[i][3], white)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,16 +54,14 @@ func (l *LongCTW) Flush(buf *bytes.Buffer) {
|
||||
l.c[l.cols-2] = 1
|
||||
|
||||
for i, r := range l.d {
|
||||
p := 0
|
||||
f := true
|
||||
for j, c := range r {
|
||||
if (1<<j)&skipCol > 0 {
|
||||
continue
|
||||
}
|
||||
if f == false {
|
||||
p = 1
|
||||
fmt.Fprintf(buf, "%s", brailEmpty)
|
||||
}
|
||||
fmt.Fprintf(buf, "%*s", p, "")
|
||||
|
||||
if j == l.cols-2 {
|
||||
fmt.Fprintf(buf, "%s%*s%s", l.ic[i], l.c[j], c, white)
|
||||
|
||||
@@ -3,9 +3,10 @@ package ctw
|
||||
import "strings"
|
||||
|
||||
var (
|
||||
white string = "\033[38;2;255;255;255m"
|
||||
green string = "\033[38;2;055;183;021m"
|
||||
brown string = "\033[38;2;192;154;107m"
|
||||
white string = "\033[38;2;255;255;255m"
|
||||
green string = "\033[38;2;055;183;021m"
|
||||
brown string = "\033[38;2;192;154;107m"
|
||||
brailEmpty string = "\u2800"
|
||||
)
|
||||
|
||||
func DisplayColor(b bool) {
|
||||
@@ -16,6 +17,12 @@ func DisplayColor(b bool) {
|
||||
}
|
||||
}
|
||||
|
||||
func DisplayBrailEmpty(b bool) {
|
||||
if b == false {
|
||||
brailEmpty = " "
|
||||
}
|
||||
}
|
||||
|
||||
func getGitColor(gitStatus string) string {
|
||||
switch strings.Trim(gitStatus, " ") {
|
||||
case "":
|
||||
|
||||
@@ -56,7 +56,7 @@ func newDir(d *os.File) (*dir, error) {
|
||||
|
||||
// getting Git Status of the entire repository
|
||||
var gitRepoStatus map[string]string // could be nil
|
||||
if flagVector&flag_D == 0 {
|
||||
if flagVector&flag_D > 0 {
|
||||
gitRepoStatus = getFilesGitStatus(d.Name()) // returns map or nil
|
||||
}
|
||||
|
||||
@@ -73,6 +73,12 @@ func newDir(d *os.File) (*dir, error) {
|
||||
t.info.blocks = s.Blocks
|
||||
}
|
||||
}
|
||||
if flagVector&flag_i == 0 {
|
||||
t.info.icon = iDef["diropen"].getGlyph()
|
||||
if flagVector&flag_c == 0 {
|
||||
t.info.iconColor = iDef["diropen"].getColor(1)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// don't fill files info if the -d flag is passed
|
||||
@@ -106,9 +112,9 @@ func newDir(d *os.File) (*dir, error) {
|
||||
}
|
||||
|
||||
if flagVector&flag_i == 0 {
|
||||
f.icon = "\uf15c"
|
||||
if flagVector&flag_c == 0 {
|
||||
f.iconColor = "\033[38;2;127;213;234m"
|
||||
f.icon, f.iconColor = getIcon(f.name, f.ext, f.indicator)
|
||||
if flagVector&flag_c != 0 {
|
||||
f.iconColor = ""
|
||||
}
|
||||
}
|
||||
|
||||
@@ -154,6 +160,12 @@ func newDir(d *os.File) (*dir, error) {
|
||||
t.parent.blocks = s.Blocks
|
||||
}
|
||||
}
|
||||
if flagVector&flag_i == 0 {
|
||||
t.parent.icon = iDef["diropen"].getGlyph()
|
||||
if flagVector&flag_c == 0 {
|
||||
t.parent.iconColor = iDef["diropen"].getColor(1)
|
||||
}
|
||||
}
|
||||
t.files = append(t.files, t.parent)
|
||||
}
|
||||
|
||||
@@ -185,6 +197,12 @@ func newDir_ArgFiles(files []os.FileInfo) *dir {
|
||||
f.blocks = s.Blocks
|
||||
}
|
||||
}
|
||||
if flagVector&flag_i == 0 {
|
||||
f.icon, f.iconColor = getIcon(f.name, f.ext, f.indicator)
|
||||
if flagVector&flag_c != 0 {
|
||||
f.iconColor = ""
|
||||
}
|
||||
}
|
||||
t.files = append(t.files, f)
|
||||
}
|
||||
return t
|
||||
@@ -209,7 +227,7 @@ func newDirs_Recussion(d *os.File) {
|
||||
temp[i] = filepath.Join(d.Name(), v)
|
||||
}
|
||||
for _, v := range temp {
|
||||
fmt.Printf("\n%s:\n", v)
|
||||
fmt.Printf("\n%s:\n", openDir+v)
|
||||
f, err := os.Open(v)
|
||||
if err != nil {
|
||||
log.Printf("cannot access %q: %v\n", v, err)
|
||||
|
||||
@@ -146,3 +146,42 @@ func getSizeInFormate(b int64) string {
|
||||
return fmt.Sprintf("%.1f%c",
|
||||
float64(b)/float64(div), "KMGTPE"[exp])
|
||||
}
|
||||
|
||||
func getIcon(name, ext, indicator string) (icon, color string) {
|
||||
var i *iInfo
|
||||
var ok bool
|
||||
switch indicator {
|
||||
case "/":
|
||||
// send dir related stuff
|
||||
i, ok = Icon_Dir[strings.ToLower(name+ext)]
|
||||
if ok {
|
||||
break
|
||||
}
|
||||
if len(name) == 0 || '.' == name[0] {
|
||||
i = iDef["hiddendir"]
|
||||
break
|
||||
}
|
||||
i = iDef["dir"]
|
||||
case "*":
|
||||
// send executable related stuff
|
||||
i = iDef["exe"]
|
||||
default:
|
||||
// send file related stuff
|
||||
i, ok = Icon_FileName[strings.ToLower(name+ext)]
|
||||
if ok {
|
||||
break
|
||||
}
|
||||
|
||||
i, ok = Icon_Ext[strings.ToLower(strings.TrimPrefix(ext, "."))]
|
||||
if ok {
|
||||
break
|
||||
}
|
||||
|
||||
if len(name) == 0 || '.' == name[0] {
|
||||
i = iDef["hiddenfile"]
|
||||
break
|
||||
}
|
||||
i = iDef["file"]
|
||||
}
|
||||
return i.getGlyph(), i.getColor(1)
|
||||
}
|
||||
|
||||
@@ -0,0 +1,61 @@
|
||||
package main
|
||||
|
||||
var Icon_Dir = map[string]*iInfo{
|
||||
"config": iSet["dir-config"],
|
||||
".config": iSet["dir-config"],
|
||||
"configs": iSet["dir-config"],
|
||||
"configuration": iSet["dir-config"],
|
||||
"configurations": iSet["dir-config"],
|
||||
"settings": iSet["dir-config"],
|
||||
".settings": iSet["dir-config"],
|
||||
"META-INF": iSet["dir-config"],
|
||||
"controller": iSet["dir-controller"],
|
||||
"controllers": iSet["dir-controller"],
|
||||
"service": iSet["dir-controller"],
|
||||
"services": iSet["dir-controller"],
|
||||
"provider": iSet["dir-controller"],
|
||||
"providers": iSet["dir-controller"],
|
||||
".git": iSet["dir-git"],
|
||||
"githooks": iSet["dir-git"],
|
||||
".githooks": iSet["dir-git"],
|
||||
"submodules": iSet["dir-git"],
|
||||
".submodules": iSet["dir-git"],
|
||||
".github": iSet["dir-github"],
|
||||
"node_modules": iSet["dir-npm"],
|
||||
"include": iSet["dir-include"],
|
||||
"includes": iSet["dir-include"],
|
||||
"_includes": iSet["dir-include"],
|
||||
"import": iSet["dir-import"],
|
||||
"imports": iSet["dir-import"],
|
||||
"imported": iSet["dir-import"],
|
||||
"uploads": iSet["dir-upload"],
|
||||
"upload": iSet["dir-upload"],
|
||||
"downloads": iSet["dir-download"],
|
||||
"download": iSet["dir-download"],
|
||||
"auth": iSet["dir-secure"],
|
||||
"authentication": iSet["dir-secure"],
|
||||
"secure": iSet["dir-secure"],
|
||||
"security": iSet["dir-secure"],
|
||||
"cert": iSet["dir-secure"],
|
||||
"certs": iSet["dir-secure"],
|
||||
"certificate": iSet["dir-secure"],
|
||||
"certificates": iSet["dir-secure"],
|
||||
"ssl": iSet["dir-secure"],
|
||||
"images": iSet["dir-images"],
|
||||
"image": iSet["dir-images"],
|
||||
"pics": iSet["dir-images"],
|
||||
"pic": iSet["dir-images"],
|
||||
"pictures": iSet["dir-images"],
|
||||
"picture": iSet["dir-images"],
|
||||
"img": iSet["dir-images"],
|
||||
"icons": iSet["dir-images"],
|
||||
"icon": iSet["dir-images"],
|
||||
"ico": iSet["dir-images"],
|
||||
"screenshot": iSet["dir-images"],
|
||||
"screenshots": iSet["dir-images"],
|
||||
".env": iSet["dir-environment"],
|
||||
".environment": iSet["dir-environment"],
|
||||
"env": iSet["dir-environment"],
|
||||
"environment": iSet["dir-environment"],
|
||||
"environments": iSet["dir-environment"],
|
||||
}
|
||||
@@ -0,0 +1,530 @@
|
||||
package main
|
||||
|
||||
var Icon_Ext = map[string]*iInfo{
|
||||
"htm": iSet["html"],
|
||||
"html": iSet["html"],
|
||||
"xhtml": iSet["html"],
|
||||
"html_vm": iSet["html"],
|
||||
"asp": iSet["html"],
|
||||
"jade": iSet["pug"],
|
||||
"pug": iSet["pug"],
|
||||
"md": iSet["markdown"],
|
||||
"markdown": iSet["markdown"],
|
||||
"rst": iSet["markdown"],
|
||||
"blink": iSet["blink"],
|
||||
"css": iSet["css"],
|
||||
"scss": iSet["sass"],
|
||||
"sass": iSet["sass"],
|
||||
"less": iSet["less"],
|
||||
"json": iSet["json"],
|
||||
"tsbuildinfo": iSet["json"],
|
||||
"json5": iSet["json"],
|
||||
"jsonl": iSet["json"],
|
||||
"ndjson": iSet["json"],
|
||||
"jinja": iSet["jinja"],
|
||||
"jinja2": iSet["jinja"],
|
||||
"j2": iSet["jinja"],
|
||||
"jinja-html": iSet["jinja"],
|
||||
"sublime-project": iSet["sublime"],
|
||||
"sublime-workspace": iSet["sublime"],
|
||||
"yaml": iSet["yaml"],
|
||||
"yaml-tmlanguage": iSet["yaml"],
|
||||
"yml": iSet["yaml"],
|
||||
"xml": iSet["xml"],
|
||||
"plist": iSet["xml"],
|
||||
"xsd": iSet["xml"],
|
||||
"dtd": iSet["xml"],
|
||||
"xsl": iSet["xml"],
|
||||
"xslt": iSet["xml"],
|
||||
"resx": iSet["xml"],
|
||||
"iml": iSet["xml"],
|
||||
"xquery": iSet["xml"],
|
||||
"tmLanguage": iSet["xml"],
|
||||
"manifest": iSet["xml"],
|
||||
"project": iSet["xml"],
|
||||
"png": iSet["image"],
|
||||
"jpeg": iSet["image"],
|
||||
"jpg": iSet["image"],
|
||||
"gif": iSet["image"],
|
||||
"ico": iSet["image"],
|
||||
"tif": iSet["image"],
|
||||
"tiff": iSet["image"],
|
||||
"psd": iSet["image"],
|
||||
"psb": iSet["image"],
|
||||
"ami": iSet["image"],
|
||||
"apx": iSet["image"],
|
||||
"bmp": iSet["image"],
|
||||
"bpg": iSet["image"],
|
||||
"brk": iSet["image"],
|
||||
"cur": iSet["image"],
|
||||
"dds": iSet["image"],
|
||||
"dng": iSet["image"],
|
||||
"exr": iSet["image"],
|
||||
"fpx": iSet["image"],
|
||||
"gbr": iSet["image"],
|
||||
"img": iSet["image"],
|
||||
"jbig2": iSet["image"],
|
||||
"jb2": iSet["image"],
|
||||
"jng": iSet["image"],
|
||||
"jxr": iSet["image"],
|
||||
"pbm": iSet["image"],
|
||||
"pgf": iSet["image"],
|
||||
"pic": iSet["image"],
|
||||
"raw": iSet["image"],
|
||||
"webp": iSet["image"],
|
||||
"eps": iSet["image"],
|
||||
"afphoto": iSet["image"],
|
||||
"ase": iSet["image"],
|
||||
"aseprite": iSet["image"],
|
||||
"clip": iSet["image"],
|
||||
"cpt": iSet["image"],
|
||||
"heif": iSet["image"],
|
||||
"heic": iSet["image"],
|
||||
"kra": iSet["image"],
|
||||
"mdp": iSet["image"],
|
||||
"ora": iSet["image"],
|
||||
"pdn": iSet["image"],
|
||||
"reb": iSet["image"],
|
||||
"sai": iSet["image"],
|
||||
"tga": iSet["image"],
|
||||
"xcf": iSet["image"],
|
||||
"js": iSet["javascript"],
|
||||
"esx": iSet["javascript"],
|
||||
"mj": iSet["javascript"],
|
||||
"jsx": iSet["react"],
|
||||
"tsx": iSet["react_ts"],
|
||||
"ini": iSet["settings"],
|
||||
"dlc": iSet["settings"],
|
||||
"dll": iSet["settings"],
|
||||
"config": iSet["settings"],
|
||||
"conf": iSet["settings"],
|
||||
"properties": iSet["settings"],
|
||||
"prop": iSet["settings"],
|
||||
"settings": iSet["settings"],
|
||||
"option": iSet["settings"],
|
||||
"props": iSet["settings"],
|
||||
"toml": iSet["settings"],
|
||||
"prefs": iSet["settings"],
|
||||
"dotsettings": iSet["settings"],
|
||||
"cfg": iSet["settings"],
|
||||
"ts": iSet["typescript"],
|
||||
"marko": iSet["markojs"],
|
||||
"pdf": iSet["pdf"],
|
||||
"xlsx": iSet["table"],
|
||||
"xls": iSet["table"],
|
||||
"csv": iSet["table"],
|
||||
"tsv": iSet["table"],
|
||||
"vscodeignore": iSet["vscode"],
|
||||
"vsixmanifest": iSet["vscode"],
|
||||
"vsix": iSet["vscode"],
|
||||
"code-workplace": iSet["vscode"],
|
||||
"csproj": iSet["visualstudio"],
|
||||
"ruleset": iSet["visualstudio"],
|
||||
"sln": iSet["visualstudio"],
|
||||
"suo": iSet["visualstudio"],
|
||||
"vb": iSet["visualstudio"],
|
||||
"vbs": iSet["visualstudio"],
|
||||
"vcxitems": iSet["visualstudio"],
|
||||
"vcxproj": iSet["visualstudio"],
|
||||
"pdb": iSet["database"],
|
||||
"sql": iSet["mysql"],
|
||||
"pks": iSet["database"],
|
||||
"pkb": iSet["database"],
|
||||
"accdb": iSet["database"],
|
||||
"mdb": iSet["database"],
|
||||
"sqlite": iSet["sqlite"],
|
||||
"sqlite3": iSet["sqlite"],
|
||||
"pgsql": iSet["postgresql"],
|
||||
"postgres": iSet["postgresql"],
|
||||
"psql": iSet["postgresql"],
|
||||
"cs": iSet["csharp"],
|
||||
"csx": iSet["csharp"],
|
||||
"qs": iSet["qsharp"],
|
||||
"zip": iSet["zip"],
|
||||
"tar": iSet["zip"],
|
||||
"gz": iSet["zip"],
|
||||
"xz": iSet["zip"],
|
||||
"br": iSet["zip"],
|
||||
"bzip2": iSet["zip"],
|
||||
"gzip": iSet["zip"],
|
||||
"brotli": iSet["zip"],
|
||||
"7z": iSet["zip"],
|
||||
"rar": iSet["zip"],
|
||||
"tgz": iSet["zip"],
|
||||
"vala": iSet["vala"],
|
||||
"zig": iSet["zig"],
|
||||
"exe": iSet["exe"],
|
||||
"msi": iSet["exe"],
|
||||
"java": iSet["java"],
|
||||
"jar": iSet["java"],
|
||||
"jsp": iSet["java"],
|
||||
"c": iSet["c"],
|
||||
"m": iSet["c"],
|
||||
"i": iSet["c"],
|
||||
"mi": iSet["c"],
|
||||
"h": iSet["h"],
|
||||
"cc": iSet["cpp"],
|
||||
"cpp": iSet["cpp"],
|
||||
"cxx": iSet["cpp"],
|
||||
"c++": iSet["cpp"],
|
||||
"cp": iSet["cpp"],
|
||||
"mm": iSet["cpp"],
|
||||
"mii": iSet["cpp"],
|
||||
"ii": iSet["cpp"],
|
||||
"hh": iSet["hpp"],
|
||||
"hpp": iSet["hpp"],
|
||||
"hxx": iSet["hpp"],
|
||||
"h++": iSet["hpp"],
|
||||
"hp": iSet["hpp"],
|
||||
"tcc": iSet["hpp"],
|
||||
"inl": iSet["hpp"],
|
||||
"go": iSet["go"],
|
||||
"py": iSet["python"],
|
||||
"pyc": iSet["python-misc"],
|
||||
"whl": iSet["python-misc"],
|
||||
"url": iSet["url"],
|
||||
"sh": iSet["console"],
|
||||
"ksh": iSet["console"],
|
||||
"csh": iSet["console"],
|
||||
"tcsh": iSet["console"],
|
||||
"zsh": iSet["console"],
|
||||
"bash": iSet["console"],
|
||||
"bat": iSet["console"],
|
||||
"cmd": iSet["console"],
|
||||
"awk": iSet["console"],
|
||||
"fish": iSet["console"],
|
||||
"ps1": iSet["powershell"],
|
||||
"psm1": iSet["powershell"],
|
||||
"psd1": iSet["powershell"],
|
||||
"ps1xml": iSet["powershell"],
|
||||
"psc1": iSet["powershell"],
|
||||
"pssc": iSet["powershell"],
|
||||
"gradle": iSet["gradle"],
|
||||
"doc": iSet["word"],
|
||||
"docx": iSet["word"],
|
||||
"rtf": iSet["word"],
|
||||
"cer": iSet["certificate"],
|
||||
"cert": iSet["certificate"],
|
||||
"crt": iSet["certificate"],
|
||||
"pub": iSet["key"],
|
||||
"key": iSet["key"],
|
||||
"pem": iSet["key"],
|
||||
"asc": iSet["key"],
|
||||
"gpg": iSet["key"],
|
||||
"woff": iSet["font"],
|
||||
"woff2": iSet["font"],
|
||||
"ttf": iSet["font"],
|
||||
"eot": iSet["font"],
|
||||
"suit": iSet["font"],
|
||||
"otf": iSet["font"],
|
||||
"bmap": iSet["font"],
|
||||
"fnt": iSet["font"],
|
||||
"odttf": iSet["font"],
|
||||
"ttc": iSet["font"],
|
||||
"font": iSet["font"],
|
||||
"fonts": iSet["font"],
|
||||
"sui": iSet["font"],
|
||||
"ntf": iSet["font"],
|
||||
"mrf": iSet["font"],
|
||||
"lib": iSet["lib"],
|
||||
"bib": iSet["lib"],
|
||||
"rb": iSet["ruby"],
|
||||
"erb": iSet["ruby"],
|
||||
"fs": iSet["fsharp"],
|
||||
"fsx": iSet["fsharp"],
|
||||
"fsi": iSet["fsharp"],
|
||||
"fsproj": iSet["fsharp"],
|
||||
"swift": iSet["swift"],
|
||||
"ino": iSet["arduino"],
|
||||
"dockerignore": iSet["docker"],
|
||||
"dockerfile": iSet["docker"],
|
||||
"tex": iSet["tex"],
|
||||
"sty": iSet["tex"],
|
||||
"dtx": iSet["tex"],
|
||||
"ltx": iSet["tex"],
|
||||
"pptx": iSet["powerpoint"],
|
||||
"ppt": iSet["powerpoint"],
|
||||
"pptm": iSet["powerpoint"],
|
||||
"potx": iSet["powerpoint"],
|
||||
"potm": iSet["powerpoint"],
|
||||
"ppsx": iSet["powerpoint"],
|
||||
"ppsm": iSet["powerpoint"],
|
||||
"pps": iSet["powerpoint"],
|
||||
"ppam": iSet["powerpoint"],
|
||||
"ppa": iSet["powerpoint"],
|
||||
"webm": iSet["video"],
|
||||
"mkv": iSet["video"],
|
||||
"flv": iSet["video"],
|
||||
"vob": iSet["video"],
|
||||
"ogv": iSet["video"],
|
||||
"ogg": iSet["video"],
|
||||
"gifv": iSet["video"],
|
||||
"avi": iSet["video"],
|
||||
"mov": iSet["video"],
|
||||
"qt": iSet["video"],
|
||||
"wmv": iSet["video"],
|
||||
"yuv": iSet["video"],
|
||||
"rm": iSet["video"],
|
||||
"rmvb": iSet["video"],
|
||||
"mp4": iSet["video"],
|
||||
"m4v": iSet["video"],
|
||||
"mpg": iSet["video"],
|
||||
"mp2": iSet["video"],
|
||||
"mpeg": iSet["video"],
|
||||
"mpe": iSet["video"],
|
||||
"mpv": iSet["video"],
|
||||
"m2v": iSet["video"],
|
||||
"vdi": iSet["virtual"],
|
||||
"vbox": iSet["virtual"],
|
||||
"vbox-prev": iSet["virtual"],
|
||||
"ics": iSet["email"],
|
||||
"mp3": iSet["audio"],
|
||||
"flac": iSet["audio"],
|
||||
"m4a": iSet["audio"],
|
||||
"wma": iSet["audio"],
|
||||
"aiff": iSet["audio"],
|
||||
"coffee": iSet["coffee"],
|
||||
"cson": iSet["coffee"],
|
||||
"iced": iSet["coffee"],
|
||||
"txt": iSet["document"],
|
||||
"graphql": iSet["graphql"],
|
||||
"gql": iSet["graphql"],
|
||||
"rs": iSet["rust"],
|
||||
"raml": iSet["raml"],
|
||||
"xaml": iSet["xaml"],
|
||||
"hs": iSet["haskell"],
|
||||
"kt": iSet["kotlin"],
|
||||
"kts": iSet["kotlin"],
|
||||
"patch": iSet["git"],
|
||||
"lua": iSet["lua"],
|
||||
"clj": iSet["clojure"],
|
||||
"cljs": iSet["clojure"],
|
||||
"cljc": iSet["clojure"],
|
||||
"groovy": iSet["groovy"],
|
||||
"r": iSet["r"],
|
||||
"rmd": iSet["r"],
|
||||
"dart": iSet["dart"],
|
||||
"as": iSet["actionscript"],
|
||||
"mxml": iSet["mxml"],
|
||||
"ahk": iSet["autohotkey"],
|
||||
"swf": iSet["flash"],
|
||||
"swc": iSet["swc"],
|
||||
"cmake": iSet["cmake"],
|
||||
"asm": iSet["assembly"],
|
||||
"a51": iSet["assembly"],
|
||||
"inc": iSet["assembly"],
|
||||
"nasm": iSet["assembly"],
|
||||
"s": iSet["assembly"],
|
||||
"ms": iSet["assembly"],
|
||||
"agc": iSet["assembly"],
|
||||
"ags": iSet["assembly"],
|
||||
"aea": iSet["assembly"],
|
||||
"argus": iSet["assembly"],
|
||||
"mitigus": iSet["assembly"],
|
||||
"binsource": iSet["assembly"],
|
||||
"vue": iSet["vue"],
|
||||
"ml": iSet["ocaml"],
|
||||
"mli": iSet["ocaml"],
|
||||
"cmx": iSet["ocaml"],
|
||||
"lock": iSet["lock"],
|
||||
"hbs": iSet["handlebars"],
|
||||
"mustache": iSet["handlebars"],
|
||||
"pm": iSet["perl"],
|
||||
"raku": iSet["perl"],
|
||||
"hx": iSet["haxe"],
|
||||
"pp": iSet["puppet"],
|
||||
"ex": iSet["elixir"],
|
||||
"exs": iSet["elixir"],
|
||||
"eex": iSet["elixir"],
|
||||
"leex": iSet["elixir"],
|
||||
"erl": iSet["erlang"],
|
||||
"twig": iSet["twig"],
|
||||
"jl": iSet["julia"],
|
||||
"elm": iSet["elm"],
|
||||
"pure": iSet["purescript"],
|
||||
"purs": iSet["purescript"],
|
||||
"tpl": iSet["smarty"],
|
||||
"styl": iSet["stylus"],
|
||||
"merlin": iSet["merlin"],
|
||||
"v": iSet["verilog"],
|
||||
"vhd": iSet["verilog"],
|
||||
"sv": iSet["verilog"],
|
||||
"svh": iSet["verilog"],
|
||||
"robot": iSet["robot"],
|
||||
"sol": iSet["solidity"],
|
||||
"yang": iSet["yang"],
|
||||
"mjml": iSet["mjml"],
|
||||
"tf": iSet["terraform"],
|
||||
"tfvars": iSet["terraform"],
|
||||
"tfstate": iSet["terraform"],
|
||||
"applescript": iSet["applescript"],
|
||||
"ipa": iSet["applescript"],
|
||||
"cake": iSet["cake"],
|
||||
"nim": iSet["nim"],
|
||||
"nimble": iSet["nim"],
|
||||
"apib": iSet["apiblueprint"],
|
||||
"apiblueprint": iSet["apiblueprint"],
|
||||
"pcss": iSet["postcss"],
|
||||
"sss": iSet["postcss"],
|
||||
"todo": iSet["todo"],
|
||||
"nix": iSet["nix"],
|
||||
"slim": iSet["slim"],
|
||||
"http": iSet["http"],
|
||||
"rest": iSet["http"],
|
||||
"apk": iSet["android"],
|
||||
"env": iSet["tune"],
|
||||
"jenkinsfile": iSet["jenkins"],
|
||||
"jenkins": iSet["jenkins"],
|
||||
"log": iSet["log"],
|
||||
"ejs": iSet["ejs"],
|
||||
"djt": iSet["django"],
|
||||
"pot": iSet["i18n"],
|
||||
"po": iSet["i18n"],
|
||||
"mo": iSet["i18n"],
|
||||
"d": iSet["d"],
|
||||
"mdx": iSet["mdx"],
|
||||
"gd": iSet["godot"],
|
||||
"godot": iSet["godot-assets"],
|
||||
"tres": iSet["godot-assets"],
|
||||
"tscn": iSet["godot-assets"],
|
||||
"azcli": iSet["azure"],
|
||||
"vagrantfile": iSet["vagrant"],
|
||||
"cshtml": iSet["razor"],
|
||||
"vbhtml": iSet["razor"],
|
||||
"ad": iSet["asciidoc"],
|
||||
"adoc": iSet["asciidoc"],
|
||||
"asciidoc": iSet["asciidoc"],
|
||||
"edge": iSet["edge"],
|
||||
"ss": iSet["scheme"],
|
||||
"scm": iSet["scheme"],
|
||||
"stl": iSet["3d"],
|
||||
"obj": iSet["3d"],
|
||||
"ac": iSet["3d"],
|
||||
"blend": iSet["3d"],
|
||||
"mesh": iSet["3d"],
|
||||
"mqo": iSet["3d"],
|
||||
"pmd": iSet["3d"],
|
||||
"pmx": iSet["3d"],
|
||||
"skp": iSet["3d"],
|
||||
"vac": iSet["3d"],
|
||||
"vdp": iSet["3d"],
|
||||
"vox": iSet["3d"],
|
||||
"svg": iSet["svg"],
|
||||
"vimrc": iSet["vim"],
|
||||
"gvimrc": iSet["vim"],
|
||||
"exrc": iSet["vim"],
|
||||
"moon": iSet["moonscript"],
|
||||
"iso": iSet["disc"],
|
||||
"f": iSet["fortran"],
|
||||
"f77": iSet["fortran"],
|
||||
"f90": iSet["fortran"],
|
||||
"f95": iSet["fortran"],
|
||||
"f03": iSet["fortran"],
|
||||
"f08": iSet["fortran"],
|
||||
"tcl": iSet["tcl"],
|
||||
"liquid": iSet["liquid"],
|
||||
"p": iSet["prolog"],
|
||||
"pro": iSet["prolog"],
|
||||
"coco": iSet["coconut"],
|
||||
"sketch": iSet["sketch"],
|
||||
"opam": iSet["opam"],
|
||||
"dhallb": iSet["dhall"],
|
||||
"pwn": iSet["pawn"],
|
||||
"amx": iSet["pawn"],
|
||||
"dhall": iSet["dhall"],
|
||||
"pas": iSet["pascal"],
|
||||
"unity": iSet["shaderlab"],
|
||||
"nupkg": iSet["nuget"],
|
||||
"command": iSet["command"],
|
||||
"dsc": iSet["denizenscript"],
|
||||
// "ls": iSet["livescript"],
|
||||
// "re": iSet["reason"],
|
||||
// "rei": iSet["reason"],
|
||||
// "cmj": iSet["bucklescript"],
|
||||
// "nb": iSet["mathematica"],
|
||||
// "wl": iSet["wolframlanguage"],
|
||||
// "wls": iSet["wolframlanguage"],
|
||||
// "njk": iSet["nunjucks"],
|
||||
// "nunjucks": iSet["nunjucks"],
|
||||
// "au3": iSet["autoit"],
|
||||
// "haml": iSet["haml"],
|
||||
// "feature": iSet["cucumber"],
|
||||
// "riot": iSet["riot"],
|
||||
// "tag": iSet["riot"],
|
||||
// "vfl": iSet["vfl"],
|
||||
// "kl": iSet["kl"],
|
||||
// "cfml": iSet["coldfusion"],
|
||||
// "cfc": iSet["coldfusion"],
|
||||
// "lucee": iSet["coldfusion"],
|
||||
// "cfm": iSet["coldfusion"],
|
||||
// "cabal": iSet["cabal"],
|
||||
// "rql": iSet["restql"],
|
||||
// "restql": iSet["restql"],
|
||||
// "kv": iSet["kivy"],
|
||||
// "graphcool": iSet["graphcool"],
|
||||
// "sbt": iSet["sbt"],
|
||||
// "cr": iSet["crystal"],
|
||||
// "ecr": iSet["crystal"],
|
||||
// "cu": iSet["cuda"],
|
||||
// "cuh": iSet["cuda"],
|
||||
// "def": iSet["dotjs"],
|
||||
// "dot": iSet["dotjs"],
|
||||
// "jst": iSet["dotjs"],
|
||||
// "pde": iSet["processing"],
|
||||
// "wpy": iSet["wepy"],
|
||||
// "hcl": iSet["hcl"],
|
||||
// "san": iSet["san"],
|
||||
// "red": iSet["red"],
|
||||
// "fxp": iSet["foxpro"],
|
||||
// "prg": iSet["foxpro"],
|
||||
// "wat": iSet["webassembly"],
|
||||
// "wasm": iSet["webassembly"],
|
||||
// "ipynb": iSet["jupyter"],
|
||||
// "bal": iSet["ballerina"],
|
||||
// "balx": iSet["ballerina"],
|
||||
// "rkt": iSet["racket"],
|
||||
// "bzl": iSet["bazel"],
|
||||
// "bazel": iSet["bazel"],
|
||||
// "mint": iSet["mint"],
|
||||
// "vm": iSet["velocity"],
|
||||
// "fhtml": iSet["velocity"],
|
||||
// "vtl": iSet["velocity"],
|
||||
// "prisma": iSet["prisma"],
|
||||
// "abc": iSet["abc"],
|
||||
// "lisp": iSet["lisp"],
|
||||
// "lsp": iSet["lisp"],
|
||||
// "cl": iSet["lisp"],
|
||||
// "fast": iSet["lisp"],
|
||||
// "svelte": iSet["svelte"],
|
||||
// "prw": iSet["advpl_prw"],
|
||||
// "prx": iSet["advpl_prw"],
|
||||
// "ptm": iSet["advpl_ptm"],
|
||||
// "tlpp": iSet["advpl_tlpp"],
|
||||
// "ch": iSet["advpl_include"],
|
||||
// "4th": iSet["forth"],
|
||||
// "fth": iSet["forth"],
|
||||
// "frt": iSet["forth"],
|
||||
// "iuml": iSet["uml"],
|
||||
// "pu": iSet["uml"],
|
||||
// "puml": iSet["uml"],
|
||||
// "plantuml": iSet["uml"],
|
||||
// "wsd": iSet["uml"],
|
||||
// "sml": iSet["sml"],
|
||||
// "mlton": iSet["sml"],
|
||||
// "mlb": iSet["sml"],
|
||||
// "sig": iSet["sml"],
|
||||
// "fun": iSet["sml"],
|
||||
// "cm": iSet["sml"],
|
||||
// "lex": iSet["sml"],
|
||||
// "use": iSet["sml"],
|
||||
// "grm": iSet["sml"],
|
||||
// "imba": iSet["imba"],
|
||||
// "drawio": iSet["drawio"],
|
||||
// "dio": iSet["drawio"],
|
||||
// "sas": iSet["sas"],
|
||||
// "sas7bdat": iSet["sas"],
|
||||
// "sashdat": iSet["sas"],
|
||||
// "astore": iSet["sas"],
|
||||
// "ast": iSet["sas"],
|
||||
// "sast": iSet["sas"],
|
||||
}
|
||||
@@ -0,0 +1,406 @@
|
||||
package main
|
||||
|
||||
var Icon_FileName = map[string]*iInfo{
|
||||
".pug-lintrc": iSet["pug"],
|
||||
".pug-lintrc.js": iSet["pug"],
|
||||
".pug-lintrc.json": iSet["pug"],
|
||||
".jscsrc": iSet["json"],
|
||||
".jshintrc": iSet["json"],
|
||||
"composer.lock": iSet["json"],
|
||||
".jsbeautifyrc": iSet["json"],
|
||||
".esformatter": iSet["json"],
|
||||
"cdp.pid": iSet["json"],
|
||||
".mjmlconfig": iSet["json"],
|
||||
".htaccess": iSet["xml"],
|
||||
".jshintignore": iSet["settings"],
|
||||
".buildignore": iSet["settings"],
|
||||
".mrconfig": iSet["settings"],
|
||||
".yardopts": iSet["settings"],
|
||||
"manifest.mf": iSet["settings"],
|
||||
".clang-format": iSet["settings"],
|
||||
".clang-tidy": iSet["settings"],
|
||||
"go.mod": iSet["go-mod"],
|
||||
"go.sum": iSet["go-mod"],
|
||||
"requirements.txt": iSet["python-misc"],
|
||||
"pipfile": iSet["python-misc"],
|
||||
".python-version": iSet["python-misc"],
|
||||
"manifest.in": iSet["python-misc"],
|
||||
"gradle.properties": iSet["gradle"],
|
||||
"gradlew": iSet["gradle"],
|
||||
"gradle-wrapper.properties": iSet["gradle"],
|
||||
"license": iSet["certificate"],
|
||||
"license.md": iSet["certificate"],
|
||||
"license.txt": iSet["certificate"],
|
||||
"licence": iSet["certificate"],
|
||||
"licence.md": iSet["certificate"],
|
||||
"licence.txt": iSet["certificate"],
|
||||
"unlicense": iSet["certificate"],
|
||||
"unlicense.md": iSet["certificate"],
|
||||
"unlicense.txt": iSet["certificate"],
|
||||
".htpasswd": iSet["key"],
|
||||
"gemfile": iSet["gemfile"],
|
||||
"dockerfile": iSet["docker"],
|
||||
"dockerfile.prod": iSet["docker"],
|
||||
"dockerfile.production": iSet["docker"],
|
||||
"docker-compose.yml": iSet["docker"],
|
||||
"docker-compose.yaml": iSet["docker"],
|
||||
"docker-compose.dev.yml": iSet["docker"],
|
||||
"docker-compose.local.yml": iSet["docker"],
|
||||
"docker-compose.ci.yml": iSet["docker"],
|
||||
"docker-compose.override.yml": iSet["docker"],
|
||||
"docker-compose.staging.yml": iSet["docker"],
|
||||
"docker-compose.prod.yml": iSet["docker"],
|
||||
"docker-compose.production.yml": iSet["docker"],
|
||||
"docker-compose.test.yml": iSet["docker"],
|
||||
".mailmap": iSet["email"],
|
||||
".graphqlconfig": iSet["graphql"],
|
||||
".gitignore": iSet["git"],
|
||||
".gitconfig": iSet["git"],
|
||||
".gitattributes": iSet["git"],
|
||||
".gitmodules": iSet["git"],
|
||||
".gitkeep": iSet["git"],
|
||||
"git-history": iSet["git"],
|
||||
".luacheckrc": iSet["lua"],
|
||||
".Rhistory": iSet["r"],
|
||||
"cmakelists.txt": iSet["cmake"],
|
||||
"cmakecache.txt": iSet["cmake"],
|
||||
"vue.config.js": iSet["vue-config"],
|
||||
"vue.config.ts": iSet["vue-config"],
|
||||
"nuxt.config.js": iSet["nuxt"],
|
||||
"nuxt.config.ts": iSet["nuxt"],
|
||||
"security.md": iSet["lock"],
|
||||
"security.txt": iSet["lock"],
|
||||
"security": iSet["lock"],
|
||||
"vercel.json": iSet["vercel"],
|
||||
".vercelignore": iSet["vercel"],
|
||||
"now.json": iSet["vercel"],
|
||||
".nowignore": iSet["vercel"],
|
||||
"postcss.config.js": iSet["postcss"],
|
||||
".postcssrc.js": iSet["postcss"],
|
||||
".postcssrc": iSet["postcss"],
|
||||
".postcssrc.json": iSet["postcss"],
|
||||
".postcssrc.yml": iSet["postcss"],
|
||||
"CNAME": iSet["http"],
|
||||
"webpack.js": iSet["webpack"],
|
||||
"webpack.ts": iSet["webpack"],
|
||||
"webpack.base.js": iSet["webpack"],
|
||||
"webpack.base.ts": iSet["webpack"],
|
||||
"webpack.config.js": iSet["webpack"],
|
||||
"webpack.config.ts": iSet["webpack"],
|
||||
"webpack.common.js": iSet["webpack"],
|
||||
"webpack.common.ts": iSet["webpack"],
|
||||
"webpack.config.common.js": iSet["webpack"],
|
||||
"webpack.config.common.ts": iSet["webpack"],
|
||||
"webpack.config.common.babel.js": iSet["webpack"],
|
||||
"webpack.config.common.babel.ts": iSet["webpack"],
|
||||
"webpack.dev.js": iSet["webpack"],
|
||||
"webpack.dev.ts": iSet["webpack"],
|
||||
"webpack.development.js": iSet["webpack"],
|
||||
"webpack.development.ts": iSet["webpack"],
|
||||
"webpack.config.dev.js": iSet["webpack"],
|
||||
"webpack.config.dev.ts": iSet["webpack"],
|
||||
"webpack.config.dev.babel.js": iSet["webpack"],
|
||||
"webpack.config.dev.babel.ts": iSet["webpack"],
|
||||
"webpack.prod.js": iSet["webpack"],
|
||||
"webpack.prod.ts": iSet["webpack"],
|
||||
"webpack.production.js": iSet["webpack"],
|
||||
"webpack.production.ts": iSet["webpack"],
|
||||
"webpack.server.js": iSet["webpack"],
|
||||
"webpack.server.ts": iSet["webpack"],
|
||||
"webpack.client.js": iSet["webpack"],
|
||||
"webpack.client.ts": iSet["webpack"],
|
||||
"webpack.config.server.js": iSet["webpack"],
|
||||
"webpack.config.server.ts": iSet["webpack"],
|
||||
"webpack.config.client.js": iSet["webpack"],
|
||||
"webpack.config.client.ts": iSet["webpack"],
|
||||
"webpack.config.production.babel.js": iSet["webpack"],
|
||||
"webpack.config.production.babel.ts": iSet["webpack"],
|
||||
"webpack.config.prod.babel.js": iSet["webpack"],
|
||||
"webpack.config.prod.babel.ts": iSet["webpack"],
|
||||
"webpack.config.prod.js": iSet["webpack"],
|
||||
"webpack.config.prod.ts": iSet["webpack"],
|
||||
"webpack.config.production.js": iSet["webpack"],
|
||||
"webpack.config.production.ts": iSet["webpack"],
|
||||
"webpack.config.staging.js": iSet["webpack"],
|
||||
"webpack.config.staging.ts": iSet["webpack"],
|
||||
"webpack.config.babel.js": iSet["webpack"],
|
||||
"webpack.config.babel.ts": iSet["webpack"],
|
||||
"webpack.config.base.babel.js": iSet["webpack"],
|
||||
"webpack.config.base.babel.ts": iSet["webpack"],
|
||||
"webpack.config.base.js": iSet["webpack"],
|
||||
"webpack.config.base.ts": iSet["webpack"],
|
||||
"webpack.config.staging.babel.js": iSet["webpack"],
|
||||
"webpack.config.staging.babel.ts": iSet["webpack"],
|
||||
"webpack.config.coffee": iSet["webpack"],
|
||||
"webpack.config.test.js": iSet["webpack"],
|
||||
"webpack.config.test.ts": iSet["webpack"],
|
||||
"webpack.config.vendor.js": iSet["webpack"],
|
||||
"webpack.config.vendor.ts": iSet["webpack"],
|
||||
"webpack.config.vendor.production.js": iSet["webpack"],
|
||||
"webpack.config.vendor.production.ts": iSet["webpack"],
|
||||
"webpack.test.js": iSet["webpack"],
|
||||
"webpack.test.ts": iSet["webpack"],
|
||||
"webpack.dist.js": iSet["webpack"],
|
||||
"webpack.dist.ts": iSet["webpack"],
|
||||
"webpackfile.js": iSet["webpack"],
|
||||
"webpackfile.ts": iSet["webpack"],
|
||||
"ionic.config.json": iSet["ionic"],
|
||||
".io-config.json": iSet["ionic"],
|
||||
"gulpfile.js": iSet["gulp"],
|
||||
"gulpfile.mjs": iSet["gulp"],
|
||||
"gulpfile.ts": iSet["gulp"],
|
||||
"gulpfile.babel.js": iSet["gulp"],
|
||||
"package.json": iSet["nodejs"],
|
||||
"package-lock.json": iSet["nodejs"],
|
||||
".nvmrc": iSet["nodejs"],
|
||||
".esmrc": iSet["nodejs"],
|
||||
".node-version": iSet["nodejs"],
|
||||
".npmignore": iSet["npm"],
|
||||
".npmrc": iSet["npm"],
|
||||
".yarnrc": iSet["yarn"],
|
||||
"yarn.lock": iSet["yarn"],
|
||||
".yarnclean": iSet["yarn"],
|
||||
".yarn-integrity": iSet["yarn"],
|
||||
"yarn-error.log": iSet["yarn"],
|
||||
".yarnrc.yml": iSet["yarn"],
|
||||
".yarnrc.yaml": iSet["yarn"],
|
||||
"androidmanifest.xml": iSet["android"],
|
||||
".env.defaults": iSet["tune"],
|
||||
".env.example": iSet["tune"],
|
||||
".env.sample": iSet["tune"],
|
||||
".env.schema": iSet["tune"],
|
||||
".env.local": iSet["tune"],
|
||||
".env.dev": iSet["tune"],
|
||||
".env.development": iSet["tune"],
|
||||
".env.qa": iSet["tune"],
|
||||
".env.prod": iSet["tune"],
|
||||
".env.production": iSet["tune"],
|
||||
".env.staging": iSet["tune"],
|
||||
".env.preview": iSet["tune"],
|
||||
".env.test": iSet["tune"],
|
||||
".env.testing": iSet["tune"],
|
||||
".env.development.local": iSet["tune"],
|
||||
".env.qa.local": iSet["tune"],
|
||||
".env.production.local": iSet["tune"],
|
||||
".env.staging.local": iSet["tune"],
|
||||
".env.test.local": iSet["tune"],
|
||||
".babelrc": iSet["babel"],
|
||||
".babelrc.js": iSet["babel"],
|
||||
".babelrc.json": iSet["babel"],
|
||||
"babel.config.json": iSet["babel"],
|
||||
"babel.config.js": iSet["babel"],
|
||||
"contributing.md": iSet["contributing"],
|
||||
"readme.md": iSet["readme"],
|
||||
"readme.txt": iSet["readme"],
|
||||
"readme": iSet["readme"],
|
||||
"changelog": iSet["changelog"],
|
||||
"changelog.md": iSet["changelog"],
|
||||
"changelog.txt": iSet["changelog"],
|
||||
"changes": iSet["changelog"],
|
||||
"changes.md": iSet["changelog"],
|
||||
"changes.txt": iSet["changelog"],
|
||||
"credits": iSet["credits"],
|
||||
"credits.txt": iSet["credits"],
|
||||
"credits.md": iSet["credits"],
|
||||
"authors": iSet["authors"],
|
||||
"authors.md": iSet["authors"],
|
||||
"authors.txt": iSet["authors"],
|
||||
"favicon.ico": iSet["favicon"],
|
||||
"karma.conf.js": iSet["karma"],
|
||||
"karma.conf.ts": iSet["karma"],
|
||||
"karma.conf.coffee": iSet["karma"],
|
||||
"karma.config.js": iSet["karma"],
|
||||
"karma.config.ts": iSet["karma"],
|
||||
"karma-main.js": iSet["karma"],
|
||||
"karma-main.ts": iSet["karma"],
|
||||
".travis.yml": iSet["travis"],
|
||||
".codecov.yml": iSet["codecov"],
|
||||
"codecov.yml": iSet["codecov"],
|
||||
"protractor.conf.js": iSet["protractor"],
|
||||
"protractor.conf.ts": iSet["protractor"],
|
||||
"protractor.conf.coffee": iSet["protractor"],
|
||||
"protractor.config.js": iSet["protractor"],
|
||||
"protractor.config.ts": iSet["protractor"],
|
||||
"procfile": iSet["heroku"],
|
||||
"procfile.windows": iSet["heroku"],
|
||||
".bowerrc": iSet["bower"],
|
||||
"bower.json": iSet["bower"],
|
||||
".eslintrc.js": iSet["eslint"],
|
||||
".eslintrc.cjs": iSet["eslint"],
|
||||
".eslintrc.yaml": iSet["eslint"],
|
||||
".eslintrc.yml": iSet["eslint"],
|
||||
".eslintrc.json": iSet["eslint"],
|
||||
".eslintrc": iSet["eslint"],
|
||||
".eslintignore": iSet["eslint"],
|
||||
".eslintcache": iSet["eslint"],
|
||||
"code_of_conduct.md": iSet["conduct"],
|
||||
"code_of_conduct.txt": iSet["conduct"],
|
||||
"mocha.opts": iSet["mocha"],
|
||||
".mocharc.yml": iSet["mocha"],
|
||||
".mocharc.yaml": iSet["mocha"],
|
||||
".mocharc.js": iSet["mocha"],
|
||||
".mocharc.json": iSet["mocha"],
|
||||
".mocharc.jsonc": iSet["mocha"],
|
||||
"jenkinsfile": iSet["jenkins"],
|
||||
"firebase.json": iSet["firebase"],
|
||||
".firebaserc": iSet["firebase"],
|
||||
"firestore.rules": iSet["firebase"],
|
||||
"firestore.indexes.json": iSet["firebase"],
|
||||
".stylelintrc": iSet["stylelint"],
|
||||
"stylelint.config.js": iSet["stylelint"],
|
||||
".stylelintrc.json": iSet["stylelint"],
|
||||
".stylelintrc.yaml": iSet["stylelint"],
|
||||
".stylelintrc.yml": iSet["stylelint"],
|
||||
".stylelintrc.js": iSet["stylelint"],
|
||||
".stylelintignore": iSet["stylelint"],
|
||||
".codeclimate.yml": iSet["code-climate"],
|
||||
".prettierrc": iSet["prettier"],
|
||||
"prettier.config.js": iSet["prettier"],
|
||||
".prettierrc.js": iSet["prettier"],
|
||||
".prettierrc.json": iSet["prettier"],
|
||||
".prettierrc.yaml": iSet["prettier"],
|
||||
".prettierrc.yml": iSet["prettier"],
|
||||
".prettierignore": iSet["prettier"],
|
||||
"gruntfile.js": iSet["grunt"],
|
||||
"gruntfile.ts": iSet["grunt"],
|
||||
"gruntfile.coffee": iSet["grunt"],
|
||||
"gruntfile.babel.js": iSet["grunt"],
|
||||
"gruntfile.babel.ts": iSet["grunt"],
|
||||
"gruntfile.babel.coffee": iSet["grunt"],
|
||||
"jest.config.js": iSet["jest"],
|
||||
"jest.config.ts": iSet["jest"],
|
||||
"jest.config.cjs": iSet["jest"],
|
||||
"jest.config.mjs": iSet["jest"],
|
||||
"jest.config.json": iSet["jest"],
|
||||
"jest.e2e.config.js": iSet["jest"],
|
||||
"jest.e2e.config.ts": iSet["jest"],
|
||||
"jest.e2e.config.cjs": iSet["jest"],
|
||||
"jest.e2e.config.mjs": iSet["jest"],
|
||||
"jest.e2e.config.json": iSet["jest"],
|
||||
"jest.setup.js": iSet["jest"],
|
||||
"jest.setup.ts": iSet["jest"],
|
||||
"jest.json": iSet["jest"],
|
||||
".jestrc": iSet["jest"],
|
||||
".jestrc.js": iSet["jest"],
|
||||
".jestrc.json": iSet["jest"],
|
||||
"jest.teardown.js": iSet["jest"],
|
||||
"fastfile": iSet["fastlane"],
|
||||
"appfile": iSet["fastlane"],
|
||||
".helmignore": iSet["helm"],
|
||||
"makefile": iSet["makefile"],
|
||||
".releaserc": iSet["semantic-release"],
|
||||
".releaserc.yaml": iSet["semantic-release"],
|
||||
".releaserc.yml": iSet["semantic-release"],
|
||||
".releaserc.json": iSet["semantic-release"],
|
||||
".releaserc.js": iSet["semantic-release"],
|
||||
"release.config.js": iSet["semantic-release"],
|
||||
"bitbucket-pipelines.yaml": iSet["bitbucket"],
|
||||
"bitbucket-pipelines.yml": iSet["bitbucket"],
|
||||
"azure-pipelines.yml": iSet["azure-pipelines"],
|
||||
"azure-pipelines.yaml": iSet["azure-pipelines"],
|
||||
"vagrantfile": iSet["vagrant"],
|
||||
"tailwind.js": iSet["tailwindcss"],
|
||||
"tailwind.config.js": iSet["tailwindcss"],
|
||||
"codeowners": iSet["codeowners"],
|
||||
".gcloudignore": iSet["gcp"],
|
||||
".huskyrc": iSet["husky"],
|
||||
"husky.config.js": iSet["husky"],
|
||||
".huskyrc.json": iSet["husky"],
|
||||
".huskyrc.js": iSet["husky"],
|
||||
".huskyrc.yaml": iSet["husky"],
|
||||
".huskyrc.yml": iSet["husky"],
|
||||
".commitlintrc": iSet["commitlint"],
|
||||
".commitlintrc.js": iSet["commitlint"],
|
||||
"commitlint.config.js": iSet["commitlint"],
|
||||
".commitlintrc.json": iSet["commitlint"],
|
||||
".commitlint.yaml": iSet["commitlint"],
|
||||
".commitlint.yml": iSet["commitlint"],
|
||||
"dune": iSet["dune"],
|
||||
"dune-project": iSet["dune"],
|
||||
"roadmap.md": iSet["roadmap"],
|
||||
"roadmap.txt": iSet["roadmap"],
|
||||
"timeline.md": iSet["roadmap"],
|
||||
"timeline.txt": iSet["roadmap"],
|
||||
"milestones.md": iSet["roadmap"],
|
||||
"milestones.txt": iSet["roadmap"],
|
||||
"nuget.config": iSet["nuget"],
|
||||
".nuspec": iSet["nuget"],
|
||||
"nuget.exe": iSet["nuget"],
|
||||
"stryker.conf.js": iSet["stryker"],
|
||||
"stryker.conf.json": iSet["stryker"],
|
||||
".modernizrrc": iSet["modernizr"],
|
||||
".modernizrrc.js": iSet["modernizr"],
|
||||
".modernizrrc.json": iSet["modernizr"],
|
||||
// ".vfl": iSet["vfl"],
|
||||
// ".kl": iSet["kl"],
|
||||
// "project.graphcool": iSet["graphcool"],
|
||||
// ".flowconfig": iSet["flow"],
|
||||
// ".bithoundrc": iSet["bithound"],
|
||||
// ".appveyor.yml": iSet["appveyor"],
|
||||
// "appveyor.yml": iSet["appveyor"],
|
||||
// "fuse.js": iSet["fusebox"],
|
||||
// ".editorconfig": iSet["editorconfig"],
|
||||
// ".watchmanconfig": iSet["watchman"],
|
||||
// "aurelia.json": iSet["aurelia"],
|
||||
// "rollup.config.js": iSet["rollup"],
|
||||
// "rollup.config.ts": iSet["rollup"],
|
||||
// "rollup-config.js": iSet["rollup"],
|
||||
// "rollup-config.ts": iSet["rollup"],
|
||||
// "rollup.config.common.js": iSet["rollup"],
|
||||
// "rollup.config.common.ts": iSet["rollup"],
|
||||
// "rollup.config.base.js": iSet["rollup"],
|
||||
// "rollup.config.base.ts": iSet["rollup"],
|
||||
// "rollup.config.prod.js": iSet["rollup"],
|
||||
// "rollup.config.prod.ts": iSet["rollup"],
|
||||
// "rollup.config.dev.js": iSet["rollup"],
|
||||
// "rollup.config.dev.ts": iSet["rollup"],
|
||||
// "rollup.config.prod.vendor.js": iSet["rollup"],
|
||||
// "rollup.config.prod.vendor.ts": iSet["rollup"],
|
||||
// ".hhconfig": iSet["hack"],
|
||||
// "apollo.config.js": iSet["apollo"],
|
||||
// "nodemon.json": iSet["nodemon"],
|
||||
// "nodemon-debug.json": iSet["nodemon"],
|
||||
// ".hintrc": iSet["webhint"],
|
||||
// "browserslist": iSet["browserlist"],
|
||||
// ".browserslistrc": iSet["browserlist"],
|
||||
// ".snyk": iSet["snyk"],
|
||||
// ".drone.yml": iSet["drone"],
|
||||
// ".sequelizerc": iSet["sequelize"],
|
||||
// "gatsby.config.js": iSet["gatsby"],
|
||||
// "gatsby-config.js": iSet["gatsby"],
|
||||
// "gatsby-node.js": iSet["gatsby"],
|
||||
// "gatsby-browser.js": iSet["gatsby"],
|
||||
// "gatsby-ssr.js": iSet["gatsby"],
|
||||
// ".wakatime-project": iSet["wakatime"],
|
||||
// "circle.yml": iSet["circleci"],
|
||||
// ".cfignore": iSet["cloudfoundry"],
|
||||
// "wallaby.js": iSet["wallaby"],
|
||||
// "wallaby.conf.js": iSet["wallaby"],
|
||||
// "stencil.config.js": iSet["stencil"],
|
||||
// "stencil.config.ts": iSet["stencil"],
|
||||
// ".bazelignore": iSet["bazel"],
|
||||
// ".bazelrc": iSet["bazel"],
|
||||
// "prisma.yml": iSet["prisma"],
|
||||
// ".nycrc": iSet["istanbul"],
|
||||
// ".nycrc.json": iSet["istanbul"],
|
||||
// "buildkite.yml": iSet["buildkite"],
|
||||
// "buildkite.yaml": iSet["buildkite"],
|
||||
// "netlify.json": iSet["netlify"],
|
||||
// "netlify.yml": iSet["netlify"],
|
||||
// "netlify.yaml": iSet["netlify"],
|
||||
// "netlify.toml": iSet["netlify"],
|
||||
// "nest-cli.json": iSet["nest"],
|
||||
// ".nest-cli.json": iSet["nest"],
|
||||
// "nestconfig.json": iSet["nest"],
|
||||
// ".nestconfig.json": iSet["nest"],
|
||||
// ".percy.yml": iSet["percy"],
|
||||
// ".gitpod.yml": iSet["gitpod"],
|
||||
// "tiltfile": iSet["tilt"],
|
||||
// "capacitor.config.json": iSet["capacitor"],
|
||||
// ".adonisrc.json": iSet["adonis"],
|
||||
// "ace": iSet["adonis"],
|
||||
// "meson.build": iSet["meson"],
|
||||
// ".buckconfig": iSet["buck"],
|
||||
// "nx.json": iSet["nrwl"],
|
||||
// ".slugignore": iSet["slug"],
|
||||
}
|
||||
@@ -0,0 +1,328 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
// iInfo (icon information)
|
||||
type iInfo struct {
|
||||
i string
|
||||
c [3]uint8 // represents the color in rgb (default 0,0,0 is black)
|
||||
}
|
||||
|
||||
func (i *iInfo) getGlyph() string {
|
||||
return i.i
|
||||
}
|
||||
|
||||
func (i *iInfo) getColor(f uint8) string {
|
||||
if f == 1 {
|
||||
return fmt.Sprintf("\033[38;2;%03d;%03d;%03dm", i.c[0], i.c[1], i.c[2])
|
||||
}
|
||||
return fmt.Sprintf("\033[38;2;%03d;%03d;%03dm", i.c[0], i.c[1], i.c[2])
|
||||
}
|
||||
|
||||
var iSet = map[string]*iInfo{
|
||||
"html": {"\uf13b", [3]uint8{228, 79, 57}}, // html
|
||||
"markdown": {"\uf853", [3]uint8{66, 165, 245}}, // markdown
|
||||
"css": {"\uf81b", [3]uint8{66, 165, 245}}, // css
|
||||
"sass": {"\ue603", [3]uint8{237, 80, 122}}, // sass
|
||||
"less": {"\ue60b", [3]uint8{2, 119, 189}}, // less
|
||||
"json": {"\ue60b", [3]uint8{251, 193, 60}}, // json
|
||||
"yaml": {"\ue60b", [3]uint8{244, 68, 62}}, // yaml
|
||||
"xml": {"\uf72d", [3]uint8{64, 153, 69}}, // xml
|
||||
"image": {"\uf71e", [3]uint8{48, 166, 154}}, // image
|
||||
"javascript": {"\ue74e", [3]uint8{255, 202, 61}}, // javascript
|
||||
"react": {"\ue7ba", [3]uint8{35, 188, 212}}, // react
|
||||
"react_ts": {"\ue7ba", [3]uint8{36, 142, 211}}, // react_ts
|
||||
"settings": {"\uf013", [3]uint8{66, 165, 245}}, // settings
|
||||
"typescript": {"\ue628", [3]uint8{3, 136, 209}}, // typescript
|
||||
"pdf": {"\uf724", [3]uint8{244, 68, 62}}, // pdf
|
||||
"table": {"\uf71a", [3]uint8{139, 195, 74}}, // table
|
||||
"visualstudio": {"\ue70c", [3]uint8{173, 99, 188}}, // visualstudio
|
||||
"database": {"\ue706", [3]uint8{255, 202, 61}}, // database
|
||||
"mysql": {"\ue704", [3]uint8{1, 94, 134}}, // mysql
|
||||
"postgresql": {"\ue76e", [3]uint8{49, 99, 140}}, // postgresql
|
||||
"sqlite": {"\ue7c4", [3]uint8{1, 57, 84}}, // sqlite
|
||||
"csharp": {"\uf81a", [3]uint8{2, 119, 189}}, // csharp
|
||||
"zip": {"\uf410", [3]uint8{175, 180, 43}}, // zip
|
||||
"exe": {"\uf2d0", [3]uint8{229, 77, 58}}, // exe
|
||||
"java": {"\uf675", [3]uint8{244, 68, 62}}, // java
|
||||
"c": {"\ufb70", [3]uint8{2, 119, 189}}, // c
|
||||
"cpp": {"\ufb71", [3]uint8{2, 119, 189}}, // cpp
|
||||
"go": {"\ufcd1", [3]uint8{32, 173, 194}}, // go
|
||||
"go-mod": {"\ufcd1", [3]uint8{237, 80, 122}}, // go-mod
|
||||
"python": {"\uf81f", [3]uint8{52, 102, 143}}, // python
|
||||
"python-misc": {"\uf820", [3]uint8{130, 61, 28}}, // python-misc
|
||||
"url": {"\uf836", [3]uint8{66, 165, 245}}, // url
|
||||
"console": {"\uf68c", [3]uint8{250, 111, 66}}, // console
|
||||
"word": {"\uf72b", [3]uint8{1, 87, 155}}, // word
|
||||
"certificate": {"\uf623", [3]uint8{249, 89, 63}}, // certificate
|
||||
"key": {"\uf805", [3]uint8{48, 166, 154}}, // key
|
||||
"font": {"\uf031", [3]uint8{244, 68, 62}}, // font
|
||||
"lib": {"\uf831", [3]uint8{139, 195, 74}}, // lib
|
||||
"ruby": {"\ue739", [3]uint8{229, 61, 58}}, // ruby
|
||||
"gemfile": {"\ue21e", [3]uint8{229, 61, 58}}, // gemfile
|
||||
"fsharp": {"\ue7a7", [3]uint8{55, 139, 186}}, // fsharp
|
||||
"swift": {"\ufbe3", [3]uint8{249, 95, 63}}, // swift
|
||||
"docker": {"\uf308", [3]uint8{1, 135, 201}}, // docker
|
||||
"powerpoint": {"\uf726", [3]uint8{209, 71, 51}}, // powerpoint
|
||||
"video": {"\uf72a", [3]uint8{253, 154, 62}}, // video
|
||||
"virtual": {"\uf822", [3]uint8{3, 155, 229}}, // virtual
|
||||
"email": {"\uf6ed", [3]uint8{66, 165, 245}}, // email
|
||||
"audio": {"\ufb75", [3]uint8{239, 83, 80}}, // audio
|
||||
"coffee": {"\uf675", [3]uint8{66, 165, 245}}, // coffee
|
||||
"document": {"\uf718", [3]uint8{66, 165, 245}}, // document
|
||||
"rust": {"\ue7a8", [3]uint8{250, 111, 66}}, // rust
|
||||
"raml": {"\ue60b", [3]uint8{66, 165, 245}}, // raml
|
||||
"xaml": {"\ufb72", [3]uint8{66, 165, 245}}, // xaml
|
||||
"haskell": {"\ue61f", [3]uint8{254, 168, 62}}, // haskell
|
||||
"git": {"\ue702", [3]uint8{229, 77, 58}}, // git
|
||||
"lua": {"\ue620", [3]uint8{66, 165, 245}}, // lua
|
||||
"clojure": {"\ue76a", [3]uint8{100, 221, 23}}, // clojure
|
||||
"groovy": {"\uf2a6", [3]uint8{41, 198, 218}}, // groovy
|
||||
"r": {"\ufcd2", [3]uint8{25, 118, 210}}, // r
|
||||
"dart": {"\ue798", [3]uint8{87, 182, 240}}, // dart
|
||||
"mxml": {"\uf72d", [3]uint8{254, 168, 62}}, // mxml
|
||||
"assembly": {"\uf471", [3]uint8{250, 109, 63}}, // assembly
|
||||
"vue": {"\ufd42", [3]uint8{65, 184, 131}}, // vue
|
||||
"vue-config": {"\ufd42", [3]uint8{58, 121, 110}}, // vue-config
|
||||
"lock": {"\uf83d", [3]uint8{255, 213, 79}}, // lock
|
||||
"handlebars": {"\ue60f", [3]uint8{250, 111, 66}}, // handlebars
|
||||
"perl": {"\ue769", [3]uint8{149, 117, 205}}, // perl
|
||||
"elixir": {"\ue62d", [3]uint8{149, 117, 205}}, // elixir
|
||||
"erlang": {"\ue7b1", [3]uint8{244, 68, 62}}, // erlang
|
||||
"twig": {"\ue61c", [3]uint8{155, 185, 47}}, // twig
|
||||
"julia": {"\ue624", [3]uint8{134, 82, 159}}, // julia
|
||||
"elm": {"\ue62c", [3]uint8{96, 181, 204}}, // elm
|
||||
"smarty": {"\uf834", [3]uint8{255, 207, 60}}, // smarty
|
||||
"stylus": {"\ue600", [3]uint8{192, 202, 51}}, // stylus
|
||||
"verilog": {"\ufb19", [3]uint8{250, 111, 66}}, // verilog
|
||||
"robot": {"\ufba7", [3]uint8{249, 89, 63}}, // robot
|
||||
"solidity": {"\ufcb9", [3]uint8{3, 136, 209}}, // solidity
|
||||
"yang": {"\ufb7e", [3]uint8{66, 165, 245}}, // yang
|
||||
"vercel": {"\uf47e", [3]uint8{207, 216, 220}}, // vercel
|
||||
"applescript": {"\uf302", [3]uint8{120, 144, 156}}, // applescript
|
||||
"cake": {"\uf5ea", [3]uint8{250, 111, 66}}, // cake
|
||||
"nim": {"\uf6a4", [3]uint8{255, 202, 61}}, // nim
|
||||
"todo": {"\uf058", [3]uint8{124, 179, 66}}, // todo
|
||||
"nix": {"\uf313", [3]uint8{80, 117, 193}}, // nix
|
||||
"http": {"\uf484", [3]uint8{66, 165, 245}}, // http
|
||||
"webpack": {"\ufc29", [3]uint8{142, 214, 251}}, // webpack
|
||||
"ionic": {"\ue7a9", [3]uint8{79, 143, 247}}, // ionic
|
||||
"gulp": {"\ue763", [3]uint8{229, 61, 58}}, // gulp
|
||||
"nodejs": {"\uf898", [3]uint8{139, 195, 74}}, // nodejs
|
||||
"npm": {"\ue71e", [3]uint8{203, 56, 55}}, // npm
|
||||
"yarn": {"\uf61a", [3]uint8{44, 142, 187}}, // yarn
|
||||
"android": {"\uf531", [3]uint8{139, 195, 74}}, // android
|
||||
"tune": {"\ufb69", [3]uint8{251, 193, 60}}, // tune
|
||||
"contributing": {"\uf64d", [3]uint8{255, 202, 61}}, // contributing
|
||||
"readme": {"\uf7fb", [3]uint8{66, 165, 245}}, // readme
|
||||
"changelog": {"\ufba6", [3]uint8{139, 195, 74}}, // changelog
|
||||
"credits": {"\uf75f", [3]uint8{156, 204, 101}}, // credits
|
||||
"authors": {"\uf0c0", [3]uint8{244, 68, 62}}, // authors
|
||||
"favicon": {"\ue623", [3]uint8{255, 213, 79}}, // favicon
|
||||
"karma": {"\ue622", [3]uint8{60, 190, 174}}, // karma
|
||||
"travis": {"\ue77e", [3]uint8{203, 58, 73}}, // travis
|
||||
"heroku": {"\ue607", [3]uint8{105, 99, 185}}, // heroku
|
||||
"gitlab": {"\uf296", [3]uint8{226, 69, 57}}, // gitlab
|
||||
"bower": {"\ue61a", [3]uint8{239, 88, 60}}, // bower
|
||||
"conduct": {"\uf64b", [3]uint8{205, 220, 57}}, // conduct
|
||||
"jenkins": {"\ue767", [3]uint8{240, 214, 183}}, // jenkins
|
||||
"code-climate": {"\uf7f4", [3]uint8{238, 238, 238}}, // code-climate
|
||||
"log": {"\uf719", [3]uint8{175, 180, 43}}, // log
|
||||
"ejs": {"\ue618", [3]uint8{255, 202, 61}}, // ejs
|
||||
"grunt": {"\ue611", [3]uint8{251, 170, 61}}, // grunt
|
||||
"django": {"\ue71d", [3]uint8{67, 160, 71}}, // django
|
||||
"makefile": {"\uf728", [3]uint8{239, 83, 80}}, // makefile
|
||||
"bitbucket": {"\uf171", [3]uint8{31, 136, 229}}, // bitbucket
|
||||
"d": {"\ue7af", [3]uint8{244, 68, 62}}, // d
|
||||
"mdx": {"\uf853", [3]uint8{255, 202, 61}}, // mdx
|
||||
"azure-pipelines": {"\uf427", [3]uint8{20, 101, 192}}, // azure-pipelines
|
||||
"azure": {"\ufd03", [3]uint8{31, 136, 229}}, // azure
|
||||
"razor": {"\uf564", [3]uint8{66, 165, 245}}, // razor
|
||||
"asciidoc": {"\uf718", [3]uint8{244, 68, 62}}, // asciidoc
|
||||
"edge": {"\uf564", [3]uint8{239, 111, 60}}, // edge
|
||||
"scheme": {"\ufb26", [3]uint8{244, 68, 62}}, // scheme
|
||||
"3d": {"\ue79b", [3]uint8{40, 182, 246}}, // 3d
|
||||
"svg": {"\ufc1f", [3]uint8{255, 181, 62}}, // svg
|
||||
"vim": {"\ue62b", [3]uint8{67, 160, 71}}, // vim
|
||||
"moonscript": {"\uf186", [3]uint8{251, 193, 60}}, // moonscript
|
||||
"codeowners": {"\uf507", [3]uint8{175, 180, 43}}, // codeowners
|
||||
"disc": {"\ue271", [3]uint8{176, 190, 197}}, // disc
|
||||
"fortran": {"F", [3]uint8{250, 111, 66}}, // fortran
|
||||
"tcl": {"\ufbd1", [3]uint8{239, 83, 80}}, // tcl
|
||||
"liquid": {"\ue275", [3]uint8{40, 182, 246}}, // liquid
|
||||
"prolog": {"\ue7a1", [3]uint8{239, 83, 80}}, // prolog
|
||||
"husky": {"\uf8e8", [3]uint8{229, 229, 229}}, // husky
|
||||
"coconut": {"\uf5d2", [3]uint8{141, 110, 99}}, // coconut
|
||||
"sketch": {"\uf6c7", [3]uint8{255, 194, 61}}, // sketch
|
||||
"pawn": {"\ue261", [3]uint8{239, 111, 60}}, // pawn
|
||||
"commitlint": {"\ufc16", [3]uint8{43, 150, 137}}, // commitlint
|
||||
"dhall": {"\uf448", [3]uint8{120, 144, 156}}, // dhall
|
||||
"dune": {"\uf7f4", [3]uint8{244, 127, 61}}, // dune
|
||||
"shaderlab": {"\ufbad", [3]uint8{25, 118, 210}}, // shaderlab
|
||||
"command": {"\ufb32", [3]uint8{175, 188, 194}}, // command
|
||||
"stryker": {"\uf05b", [3]uint8{239, 83, 80}}, // stryker
|
||||
"modernizr": {"\ue720", [3]uint8{234, 72, 99}}, // modernizr
|
||||
"roadmap": {"\ufb6d", [3]uint8{48, 166, 154}}, // roadmap
|
||||
"pug": {"\ue60e", [3]uint8{239, 204, 163}}, // pug (Not supported by nerdFont)
|
||||
"blink": {"\uf72a", [3]uint8{249, 169, 60}}, // blink (The Foundry Nuke) (Not supported by nerdFont)
|
||||
"postcss": {"\uf81b", [3]uint8{244, 68, 62}}, // postcss (Not supported by nerdFont)
|
||||
"jinja": {"\ue000", [3]uint8{174, 44, 42}}, // jinja (Not supported by nerdFont)
|
||||
"sublime": {"\ue7aa", [3]uint8{239, 148, 58}}, // sublime (Not supported by nerdFont)
|
||||
"markojs": {"\uf13b", [3]uint8{2, 119, 189}}, // markojs (Not supported by nerdFont)
|
||||
"vscode": {"\ue70c", [3]uint8{33, 150, 243}}, // vscode (Not supported by nerdFont)
|
||||
"qsharp": {"\uf292", [3]uint8{251, 193, 60}}, // qsharp (Not supported by nerdFont)
|
||||
"vala": {"\uf7ab", [3]uint8{149, 117, 205}}, // vala (Not supported by nerdFont)
|
||||
"zig": {"Z", [3]uint8{249, 169, 60}}, // zig (Not supported by nerdFont)
|
||||
"h": {"h", [3]uint8{2, 119, 189}}, // h (Not supported by nerdFont)
|
||||
"hpp": {"h", [3]uint8{2, 119, 189}}, // hpp (Not supported by nerdFont)
|
||||
"powershell": {"\ufcb5", [3]uint8{5, 169, 244}}, // powershell (Not supported by nerdFont)
|
||||
"gradle": {"\ufcc4", [3]uint8{29, 151, 167}}, // gradle (Not supported by nerdFont)
|
||||
"arduino": {"\ue255", [3]uint8{35, 151, 156}}, // arduino (Not supported by nerdFont)
|
||||
"tex": {"\uf783", [3]uint8{66, 165, 245}}, // tex (Not supported by nerdFont)
|
||||
"graphql": {"\ue284", [3]uint8{237, 80, 122}}, // graphql (Not supported by nerdFont)
|
||||
"kotlin": {"\ue70e", [3]uint8{139, 195, 74}}, // kotlin (Not supported by nerdFont)
|
||||
"actionscript": {"\ufb25", [3]uint8{244, 68, 62}}, // actionscript (Not supported by nerdFont)
|
||||
"autohotkey": {"\uf812", [3]uint8{76, 175, 80}}, // autohotkey (Not supported by nerdFont)
|
||||
"flash": {"\uf740", [3]uint8{198, 52, 54}}, // flash (Not supported by nerdFont)
|
||||
"swc": {"\ufbd3", [3]uint8{198, 52, 54}}, // swc (Not supported by nerdFont)
|
||||
"cmake": {"\uf425", [3]uint8{178, 178, 179}}, // cmake (Not supported by nerdFont)
|
||||
"nuxt": {"\ue2a6", [3]uint8{65, 184, 131}}, // nuxt (Not supported by nerdFont)
|
||||
"ocaml": {"\uf1ce", [3]uint8{253, 154, 62}}, // ocaml (Not supported by nerdFont)
|
||||
"haxe": {"\uf425", [3]uint8{246, 137, 61}}, // haxe (Not supported by nerdFont)
|
||||
"puppet": {"\uf595", [3]uint8{251, 193, 60}}, // puppet (Not supported by nerdFont)
|
||||
"purescript": {"\uf670", [3]uint8{66, 165, 245}}, // purescript (Not supported by nerdFont)
|
||||
"merlin": {"\uf136", [3]uint8{66, 165, 245}}, // merlin (Not supported by nerdFont)
|
||||
"mjml": {"\ue714", [3]uint8{249, 89, 63}}, // mjml (Not supported by nerdFont)
|
||||
"terraform": {"\ue20f", [3]uint8{92, 107, 192}}, // terraform (Not supported by nerdFont)
|
||||
"apiblueprint": {"\uf031", [3]uint8{66, 165, 245}}, // apiblueprint (Not supported by nerdFont)
|
||||
"slim": {"\uf24e", [3]uint8{245, 129, 61}}, // slim (Not supported by nerdFont)
|
||||
"babel": {"\uf5a0", [3]uint8{253, 217, 59}}, // babel (Not supported by nerdFont)
|
||||
"codecov": {"\ue37c", [3]uint8{237, 80, 122}}, // codecov (Not supported by nerdFont)
|
||||
"protractor": {"\uf288", [3]uint8{229, 61, 58}}, // protractor (Not supported by nerdFont)
|
||||
"eslint": {"\ufbf6", [3]uint8{121, 134, 203}}, // eslint (Not supported by nerdFont)
|
||||
"mocha": {"\uf6a9", [3]uint8{161, 136, 127}}, // mocha (Not supported by nerdFont)
|
||||
"firebase": {"\ue787", [3]uint8{251, 193, 60}}, // firebase (Not supported by nerdFont)
|
||||
"stylelint": {"\ufb76", [3]uint8{207, 216, 220}}, // stylelint (Not supported by nerdFont)
|
||||
"prettier": {"\uf8e2", [3]uint8{86, 179, 180}}, // prettier (Not supported by nerdFont)
|
||||
"jest": {"J", [3]uint8{244, 85, 62}}, // jest (Not supported by nerdFont)
|
||||
"storybook": {"\ufd2c", [3]uint8{237, 80, 122}}, // storybook (Not supported by nerdFont)
|
||||
"fastlane": {"\ufbff", [3]uint8{149, 119, 232}}, // fastlane (Not supported by nerdFont)
|
||||
"helm": {"\ufd31", [3]uint8{32, 173, 194}}, // helm (Not supported by nerdFont)
|
||||
"i18n": {"\uf7be", [3]uint8{121, 134, 203}}, // i18n (Not supported by nerdFont)
|
||||
"semantic-release": {"\uf70f", [3]uint8{245, 245, 245}}, // semantic-release (Not supported by nerdFont)
|
||||
"godot": {"\ufba7", [3]uint8{79, 195, 247}}, // godot (Not supported by nerdFont)
|
||||
"godot-assets": {"\ufba7", [3]uint8{129, 199, 132}}, // godot-assets (Not supported by nerdFont)
|
||||
"vagrant": {"\uf27d", [3]uint8{20, 101, 192}}, // vagrant (Not supported by nerdFont)
|
||||
"tailwindcss": {"\ufc8b", [3]uint8{77, 182, 172}}, // tailwindcss (Not supported by nerdFont)
|
||||
"gcp": {"\uf662", [3]uint8{70, 136, 250}}, // gcp (Not supported by nerdFont)
|
||||
"opam": {"\uf1ce", [3]uint8{255, 213, 79}}, // opam (Not supported by nerdFont)
|
||||
"pascal": {"\uf8da", [3]uint8{3, 136, 209}}, // pascal (Not supported by nerdFont)
|
||||
"nuget": {"\ue77f", [3]uint8{3, 136, 209}}, // nuget (Not supported by nerdFont)
|
||||
"denizenscript": {"D", [3]uint8{255, 213, 79}}, // denizenscript (Not supported by nerdFont)
|
||||
// "riot": {"\u", [3]uint8{255, 255, 255}}, // riot
|
||||
// "autoit": {"\u", [3]uint8{255, 255, 255}}, // autoit
|
||||
// "livescript": {"\u", [3]uint8{255, 255, 255}}, // livescript
|
||||
// "reason": {"\u", [3]uint8{255, 255, 255}}, // reason
|
||||
// "bucklescript": {"\u", [3]uint8{255, 255, 255}}, // bucklescript
|
||||
// "mathematica": {"\u", [3]uint8{255, 255, 255}}, // mathematica
|
||||
// "wolframlanguage": {"\u", [3]uint8{255, 255, 255}}, // wolframlanguage
|
||||
// "nunjucks": {"\u", [3]uint8{255, 255, 255}}, // nunjucks
|
||||
// "haml": {"\u", [3]uint8{255, 255, 255}}, // haml
|
||||
// "cucumber": {"\u", [3]uint8{255, 255, 255}}, // cucumber
|
||||
// "vfl": {"\u", [3]uint8{255, 255, 255}}, // vfl
|
||||
// "kl": {"\u", [3]uint8{255, 255, 255}}, // kl
|
||||
// "coldfusion": {"\u", [3]uint8{255, 255, 255}}, // coldfusion
|
||||
// "cabal": {"\u", [3]uint8{255, 255, 255}}, // cabal
|
||||
// "restql": {"\u", [3]uint8{255, 255, 255}}, // restql
|
||||
// "kivy": {"\u", [3]uint8{255, 255, 255}}, // kivy
|
||||
// "graphcool": {"\u", [3]uint8{255, 255, 255}}, // graphcool
|
||||
// "sbt": {"\u", [3]uint8{255, 255, 255}}, // sbt
|
||||
// "flow": {"\u", [3]uint8{255, 255, 255}}, // flow
|
||||
// "bithound": {"\u", [3]uint8{255, 255, 255}}, // bithound
|
||||
// "appveyor": {"\u", [3]uint8{255, 255, 255}}, // appveyor
|
||||
// "fusebox": {"\u", [3]uint8{255, 255, 255}}, // fusebox
|
||||
// "editorconfig": {"\u", [3]uint8{255, 255, 255}}, // editorconfig
|
||||
// "watchman": {"\u", [3]uint8{255, 255, 255}}, // watchman
|
||||
// "aurelia": {"\u", [3]uint8{255, 255, 255}}, // aurelia
|
||||
// "rollup": {"\u", [3]uint8{255, 255, 255}}, // rollup
|
||||
// "hack": {"\u", [3]uint8{255, 255, 255}}, // hack
|
||||
// "apollo": {"\u", [3]uint8{255, 255, 255}}, // apollo
|
||||
// "nodemon": {"\u", [3]uint8{255, 255, 255}}, // nodemon
|
||||
// "webhint": {"\u", [3]uint8{255, 255, 255}}, // webhint
|
||||
// "browserlist": {"\u", [3]uint8{255, 255, 255}}, // browserlist
|
||||
// "crystal": {"\u", [3]uint8{255, 255, 255}}, // crystal
|
||||
// "snyk": {"\u", [3]uint8{255, 255, 255}}, // snyk
|
||||
// "drone": {"\u", [3]uint8{255, 255, 255}}, // drone
|
||||
// "cuda": {"\u", [3]uint8{255, 255, 255}}, // cuda
|
||||
// "dotjs": {"\u", [3]uint8{255, 255, 255}}, // dotjs
|
||||
// "sequelize": {"\u", [3]uint8{255, 255, 255}}, // sequelize
|
||||
// "gatsby": {"\u", [3]uint8{255, 255, 255}}, // gatsby
|
||||
// "wakatime": {"\u", [3]uint8{255, 255, 255}}, // wakatime
|
||||
// "circleci": {"\u", [3]uint8{255, 255, 255}}, // circleci
|
||||
// "cloudfoundry": {"\u", [3]uint8{255, 255, 255}}, // cloudfoundry
|
||||
// "processing": {"\u", [3]uint8{255, 255, 255}}, // processing
|
||||
// "wepy": {"\u", [3]uint8{255, 255, 255}}, // wepy
|
||||
// "hcl": {"\u", [3]uint8{255, 255, 255}}, // hcl
|
||||
// "san": {"\u", [3]uint8{255, 255, 255}}, // san
|
||||
// "wallaby": {"\u", [3]uint8{255, 255, 255}}, // wallaby
|
||||
// "stencil": {"\u", [3]uint8{255, 255, 255}}, // stencil
|
||||
// "red": {"\u", [3]uint8{255, 255, 255}}, // red
|
||||
// "webassembly": {"\u", [3]uint8{255, 255, 255}}, // webassembly
|
||||
// "foxpro": {"\u", [3]uint8{255, 255, 255}}, // foxpro
|
||||
// "jupyter": {"\u", [3]uint8{255, 255, 255}}, // jupyter
|
||||
// "ballerina": {"\u", [3]uint8{255, 255, 255}}, // ballerina
|
||||
// "racket": {"\u", [3]uint8{255, 255, 255}}, // racket
|
||||
// "bazel": {"\u", [3]uint8{255, 255, 255}}, // bazel
|
||||
// "mint": {"\u", [3]uint8{255, 255, 255}}, // mint
|
||||
// "velocity": {"\u", [3]uint8{255, 255, 255}}, // velocity
|
||||
// "prisma": {"\u", [3]uint8{255, 255, 255}}, // prisma
|
||||
// "abc": {"\u", [3]uint8{255, 255, 255}}, // abc
|
||||
// "istanbul": {"\u", [3]uint8{255, 255, 255}}, // istanbul
|
||||
// "lisp": {"\u", [3]uint8{255, 255, 255}}, // lisp
|
||||
// "buildkite": {"\u", [3]uint8{255, 255, 255}}, // buildkite
|
||||
// "netlify": {"\u", [3]uint8{255, 255, 255}}, // netlify
|
||||
// "svelte": {"\u", [3]uint8{255, 255, 255}}, // svelte
|
||||
// "nest": {"\u", [3]uint8{255, 255, 255}}, // nest
|
||||
// "percy": {"\u", [3]uint8{255, 255, 255}}, // percy
|
||||
// "gitpod": {"\u", [3]uint8{255, 255, 255}}, // gitpod
|
||||
// "advpl_prw": {"\u", [3]uint8{255, 255, 255}}, // advpl_prw
|
||||
// "advpl_ptm": {"\u", [3]uint8{255, 255, 255}}, // advpl_ptm
|
||||
// "advpl_tlpp": {"\u", [3]uint8{255, 255, 255}}, // advpl_tlpp
|
||||
// "advpl_include": {"\u", [3]uint8{255, 255, 255}}, // advpl_include
|
||||
// "tilt": {"\u", [3]uint8{255, 255, 255}}, // tilt
|
||||
// "capacitor": {"\u", [3]uint8{255, 255, 255}}, // capacitor
|
||||
// "adonis": {"\u", [3]uint8{255, 255, 255}}, // adonis
|
||||
// "forth": {"\u", [3]uint8{255, 255, 255}}, // forth
|
||||
// "uml": {"\u", [3]uint8{255, 255, 255}}, // uml
|
||||
// "meson": {"\u", [3]uint8{255, 255, 255}}, // meson
|
||||
// "buck": {"\u", [3]uint8{255, 255, 255}}, // buck
|
||||
// "sml": {"\u", [3]uint8{255, 255, 255}}, // sml
|
||||
// "nrwl": {"\u", [3]uint8{255, 255, 255}}, // nrwl
|
||||
// "imba": {"\u", [3]uint8{255, 255, 255}}, // imba
|
||||
// "drawio": {"\u", [3]uint8{255, 255, 255}}, // drawio
|
||||
// "sas": {"\u", [3]uint8{255, 255, 255}}, // sas
|
||||
// "slug": {"\u", [3]uint8{255, 255, 255}}, // slug
|
||||
|
||||
"dir-config": {"\ue5fc", [3]uint8{32, 173, 194}}, // dir-config
|
||||
"dir-controller": {"\ue5fc", [3]uint8{255, 194, 61}}, // dir-controller
|
||||
"dir-git": {"\ue5fb", [3]uint8{250, 111, 66}}, // dir-git
|
||||
"dir-github": {"\ue5fd", [3]uint8{84, 110, 122}}, // dir-github
|
||||
"dir-npm": {"\ue5fa", [3]uint8{203, 56, 55}}, // dir-npm
|
||||
"dir-include": {"\uf756", [3]uint8{3, 155, 229}}, // dir-include
|
||||
"dir-import": {"\uf756", [3]uint8{175, 180, 43}}, // dir-import
|
||||
"dir-upload": {"\uf758", [3]uint8{250, 111, 66}}, // dir-upload
|
||||
"dir-download": {"\uf74c", [3]uint8{76, 175, 80}}, // dir-download
|
||||
"dir-secure": {"\uf74f", [3]uint8{249, 169, 60}}, // dir-secure
|
||||
"dir-images": {"\uf74e", [3]uint8{43, 150, 137}}, // dir-images
|
||||
"dir-environment": {"\uf74e", [3]uint8{102, 187, 106}}, // dir-environment
|
||||
}
|
||||
|
||||
// default icons in case nothing can be found
|
||||
var iDef = map[string]*iInfo{
|
||||
"dir": {"\uf74a", [3]uint8{224, 177, 77}},
|
||||
"diropen": {"\ufc6e", [3]uint8{224, 177, 77}},
|
||||
"hiddendir": {"\uf755", [3]uint8{224, 177, 77}},
|
||||
"exe": {"\uf713", [3]uint8{76, 175, 80}},
|
||||
"file": {"\uf723", [3]uint8{65, 129, 190}},
|
||||
"hiddenfile": {"\ufb12", [3]uint8{65, 129, 190}},
|
||||
}
|
||||
@@ -0,0 +1,94 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"fmt"
|
||||
"io"
|
||||
"log"
|
||||
"os"
|
||||
"sort"
|
||||
"testing"
|
||||
|
||||
"github.com/Yash-Handa/logo-ls/ctw"
|
||||
"golang.org/x/crypto/ssh/terminal"
|
||||
)
|
||||
|
||||
func TestFileIcons(t *testing.T) {
|
||||
log.Println("Printing each supported file name and ext by the icon pack")
|
||||
|
||||
// get terminal width
|
||||
var e error = nil
|
||||
terminalWidth, _, e = terminal.GetSize(int(os.Stdout.Fd()))
|
||||
if e != nil {
|
||||
terminalWidth = 80
|
||||
}
|
||||
|
||||
ks := make([]string, 0)
|
||||
for k := range iSet {
|
||||
ks = append(ks, k)
|
||||
}
|
||||
sort.Strings(ks)
|
||||
|
||||
for _, v := range ks {
|
||||
t.Run("Testing icon: "+v, func(st *testing.T) {
|
||||
i := iSet[v]
|
||||
fmt.Fprintln(os.Stderr)
|
||||
buf := bytes.NewBuffer([]byte(""))
|
||||
log.Println("Printing files of type", i.getColor(1)+v+"\033[38;2;255;255;255m")
|
||||
w := ctw.New(terminalWidth)
|
||||
for f, d := range Icon_FileName {
|
||||
if d == i {
|
||||
w.AddRow(" ", d.getGlyph(), f, "")
|
||||
w.IconColor(d.getColor(1))
|
||||
}
|
||||
}
|
||||
w.Flush(buf)
|
||||
io.Copy(os.Stderr, buf)
|
||||
|
||||
buf = bytes.NewBuffer([]byte(""))
|
||||
log.Println("Printing extentions of type", i.getColor(1)+v+"\033[38;2;255;255;255m")
|
||||
w = ctw.New(terminalWidth)
|
||||
for e, d := range Icon_Ext {
|
||||
if d == i {
|
||||
w.AddRow(" ", d.getGlyph(), e, "")
|
||||
w.IconColor(d.getColor(1))
|
||||
}
|
||||
}
|
||||
w.Flush(buf)
|
||||
io.Copy(os.Stderr, buf)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
func TestIconDisplay(t *testing.T) {
|
||||
// get terminal width
|
||||
var e error = nil
|
||||
terminalWidth, _, e = terminal.GetSize(int(os.Stdout.Fd()))
|
||||
if e != nil {
|
||||
terminalWidth = 80
|
||||
}
|
||||
|
||||
temp := [2]map[string]*iInfo{iSet, iDef}
|
||||
|
||||
for i, set := range temp {
|
||||
t.Run(fmt.Sprintf("Icon Set %d", i+1), func(st *testing.T) {
|
||||
//sorting alphabetically
|
||||
ks := make([]string, 0)
|
||||
for k := range set {
|
||||
ks = append(ks, k)
|
||||
}
|
||||
sort.Strings(ks)
|
||||
|
||||
// display icons
|
||||
buf := bytes.NewBuffer([]byte("\n"))
|
||||
w := ctw.New(terminalWidth)
|
||||
for _, v := range ks {
|
||||
w.AddRow(" ", set[v].getGlyph(), v, "")
|
||||
w.IconColor(set[v].getColor(1))
|
||||
}
|
||||
w.Flush(buf)
|
||||
io.Copy(os.Stdout, buf)
|
||||
fmt.Fprintln(os.Stdout)
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
[ENVIRONMENT]
|
||||
For correct display of icons the terminal should support UTF-8 encoding
|
||||
with NERD FONT <https://github.com/ryanoasis/nerd-fonts> patched font.
|
||||
For correct display of colors the terminal should support TRUE COLOR.
|
||||
|
||||
[REPORTING BUGS]
|
||||
Report Bugs to <https://github.com/Yash-Handa/logo-ls/issues>
|
||||
|
||||
[SEE ALSO]
|
||||
Full documentation with examples at: <https://www.github.com/Yash-Handa/logo-ls>
|
||||
@@ -69,13 +69,15 @@ func set_osExitCode(c int) int {
|
||||
return osExitCode
|
||||
}
|
||||
|
||||
var openDir = iDef["diropen"].getColor(1) + iDef["diropen"].getGlyph() + "\033[38;2;255;255;255m" + " "
|
||||
|
||||
func main() {
|
||||
// content flags
|
||||
f_a := getopt.BoolLong("all", 'a', "do not ignore entries starting with .")
|
||||
f_A := getopt.BoolLong("almost-all", 'A', "do not list implied . and ..")
|
||||
|
||||
// disable Stuff
|
||||
f_D := getopt.BoolLong("disable-git-status", 'D', "don't print git status of files, In recursive -R this flag enables git-status")
|
||||
f_D := getopt.BoolLong("git-status", 'D', "print git status of files")
|
||||
f_c := getopt.BoolLong("disable-color", 'c', "don't color icons, filenames and git status (use this to print to a file)")
|
||||
f_i := getopt.BoolLong("disable-icon", 'i', "don't print icons of the files")
|
||||
|
||||
@@ -97,10 +99,10 @@ func main() {
|
||||
f_t := getopt.Bool('t', "sort by modification time, newest first")
|
||||
|
||||
f_r := getopt.BoolLong("reverse", 'r', "reverse order while sorting")
|
||||
f_R := getopt.BoolLong("recursive", 'R', "list subdirectories recursively, git-status is disabled by default")
|
||||
f_R := getopt.BoolLong("recursive", 'R', "list subdirectories recursively")
|
||||
f_T := getopt.EnumLong("time-style", 'T', []string{"Stamp", "StampMilli", "Kitchen", "ANSIC", "UnixDate", "RubyDate", "RFC1123", "RFC1123Z", "RFC3339", "RFC822", "RFC822Z", "RFC850"}, "Stamp", "time/date format with -l; see time-style below")
|
||||
|
||||
f_help := getopt.Bool('?', "display this help and exit")
|
||||
f_help := getopt.BoolLong("help", '?', "display this help and exit")
|
||||
f_V := getopt.BoolLong("version", 'V', "output version information and exit")
|
||||
|
||||
// using getopt.Getopt instead of parse to provide custom err
|
||||
@@ -113,26 +115,35 @@ func main() {
|
||||
|
||||
// if f_help is provided print help and exit(0)
|
||||
if *f_help {
|
||||
fmt.Println("List information about the FILEs with ICONS and GIT STATUS (the current dir \nby default). Sort entries alphabetically if none of -tvSUX is specified.")
|
||||
|
||||
getopt.PrintUsage(os.Stdout)
|
||||
|
||||
fmt.Println("\nPossible value for --time-style (-T)")
|
||||
fmt.Printf("%-11s %-32q\n", "ANSIC", "Mon Jan _2 15:04:05 2006")
|
||||
fmt.Printf("%-11s %-32q\n", "UnixDate", "Mon Jan _2 15:04:05 MST 2006")
|
||||
fmt.Printf("%-11s %-32q\n", "RubyDate", "Mon Jan 02 15:04:05 -0700 2006")
|
||||
fmt.Printf("%-11s %-32q\n", "RFC822", "02 Jan 06 15:04 MST")
|
||||
fmt.Printf("%-11s %-32q\n", "RFC822Z", "02 Jan 06 15:04 -0700")
|
||||
fmt.Printf("%-11s %-32q\n", "RFC850", "Monday, 02-Jan-06 15:04:05 MST")
|
||||
fmt.Printf("%-11s %-32q\n", "RFC1123", "Mon, 02 Jan 2006 15:04:05 MST")
|
||||
fmt.Printf("%-11s %-32q\n", "RFC1123Z", "Mon, 02 Jan 2006 15:04:05 -0700")
|
||||
fmt.Printf("%-11s %-32q\n", "RFC3339", "2006-01-02T15:04:05Z07:00")
|
||||
fmt.Printf("%-11s %-32q\n", "Kitchen", "3:04PM")
|
||||
fmt.Printf("%-11s %-32q [Default]\n", "Stamp", "Mon Jan _2 15:04:05")
|
||||
fmt.Printf("%-11s %-32q\n", "StampMilli", "Jan _2 15:04:05.000")
|
||||
fmt.Printf(" %-11s %-32q\n", "ANSIC", "Mon Jan _2 15:04:05 2006")
|
||||
fmt.Printf(" %-11s %-32q\n", "UnixDate", "Mon Jan _2 15:04:05 MST 2006")
|
||||
fmt.Printf(" %-11s %-32q\n", "RubyDate", "Mon Jan 02 15:04:05 -0700 2006")
|
||||
fmt.Printf(" %-11s %-32q\n", "RFC822", "02 Jan 06 15:04 MST")
|
||||
fmt.Printf(" %-11s %-32q\n", "RFC822Z", "02 Jan 06 15:04 -0700")
|
||||
fmt.Printf(" %-11s %-32q\n", "RFC850", "Monday, 02-Jan-06 15:04:05 MST")
|
||||
fmt.Printf(" %-11s %-32q\n", "RFC1123", "Mon, 02 Jan 2006 15:04:05 MST")
|
||||
fmt.Printf(" %-11s %-32q\n", "RFC1123Z", "Mon, 02 Jan 2006 15:04:05 -0700")
|
||||
fmt.Printf(" %-11s %-32q\n", "RFC3339", "2006-01-02T15:04:05Z07:00")
|
||||
fmt.Printf(" %-11s %-32q\n", "Kitchen", "3:04PM")
|
||||
fmt.Printf(" %-11s %-32q [Default]\n", "Stamp", "Mon Jan _2 15:04:05")
|
||||
fmt.Printf(" %-11s %-32q\n", "StampMilli", "Jan _2 15:04:05.000")
|
||||
|
||||
fmt.Println("\nExit status:")
|
||||
fmt.Println(" 0 if OK,")
|
||||
fmt.Println(" 1 if minor problems (e.g., cannot access subdirectory),")
|
||||
fmt.Println(" 2 if serious trouble (e.g., cannot access command-line argument).")
|
||||
os.Exit(osExitCode)
|
||||
}
|
||||
|
||||
// if f_V is provided version will be printed and exit(0)
|
||||
if *f_V {
|
||||
fmt.Printf("logo-ls %s\nCopyright (c) 2020 Yash Handa\nLicense MIT <https://opensource.org/licenses/MIT>.\nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law.\n", "v1.1.0")
|
||||
fmt.Printf("logo-ls %s\nCopyright (c) 2020 Yash Handa\nLicense MIT <https://opensource.org/licenses/MIT>.\nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law.\n", "v1.3.3")
|
||||
fmt.Println("\nWritten by Yash Handa")
|
||||
os.Exit(osExitCode)
|
||||
}
|
||||
|
||||
@@ -171,7 +182,7 @@ func main() {
|
||||
}
|
||||
|
||||
// set disable-git-status (-D) flag
|
||||
if *f_D && !*f_R || !*f_D && *f_R {
|
||||
if *f_D {
|
||||
flagVector |= flag_D
|
||||
}
|
||||
|
||||
@@ -179,11 +190,14 @@ func main() {
|
||||
if *f_c {
|
||||
flagVector |= flag_c
|
||||
ctw.DisplayColor(false)
|
||||
openDir = iDef["diropen"].getGlyph() + " "
|
||||
}
|
||||
|
||||
// set disable-icon (-i) flag
|
||||
if *f_i {
|
||||
flagVector |= flag_i
|
||||
openDir = ""
|
||||
ctw.DisplayBrailEmpty(false)
|
||||
}
|
||||
|
||||
// set -1 flag
|
||||
@@ -297,9 +311,11 @@ func main() {
|
||||
}
|
||||
|
||||
// process and display all files
|
||||
io.Copy(os.Stdout, newDir_ArgFiles(args.files).print())
|
||||
if len(args.files) > 0 && len(args.dirs) > 0 {
|
||||
fmt.Println()
|
||||
if len(args.files) > 0 {
|
||||
io.Copy(os.Stdout, newDir_ArgFiles(args.files).print())
|
||||
if len(args.dirs) > 0 {
|
||||
fmt.Println()
|
||||
}
|
||||
}
|
||||
|
||||
// process and display all the dirs in arg
|
||||
@@ -309,14 +325,14 @@ func main() {
|
||||
if i > 0 {
|
||||
fmt.Println()
|
||||
}
|
||||
fmt.Printf("%s:\n", v.Name())
|
||||
fmt.Printf("%s:\n", openDir+v.Name())
|
||||
newDirs_Recussion(v)
|
||||
}
|
||||
} else {
|
||||
pName := len(dirs) > 1
|
||||
for i, v := range args.dirs {
|
||||
if pName {
|
||||
fmt.Printf("%s:\n", v.Name())
|
||||
fmt.Printf("%s:\n", openDir+v.Name())
|
||||
}
|
||||
d, err := newDir(v)
|
||||
v.Close()
|
||||
@@ -331,7 +347,6 @@ func main() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
os.Exit(osExitCode)
|
||||
}
|
||||
|
||||
|
||||