misc

package module
v0.0.0-...-fb93961 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 21, 2024 License: MIT Imports: 3 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

misc

一些工具函数

Documentation

Index

Constants

View Source
const (
	DefaultRootPath = "./"
	RootLocater     = ".root_locater"
)

Variables

This section is empty.

Functions

func GetPathInRootDir

func GetPathInRootDir(filename string) string

GetPathInRootDir 获取根目录下的文件路径 使用这个函数的前提是在项目根目录下有一个.root_locater文件

func GetRootPath

func GetRootPath() string

GetRootPath 获取根目录 使用这个函数的前提是在项目根目录下有一个.root_locater文件

func IsFileExist

func IsFileExist(filename string) bool

IsFileExist 文件是否存在

func IsRootDir

func IsRootDir(path string) bool

IsRootDir 判断是否根目录 使用这个函数的前提是在项目根目录下有一个.root_locater文件

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL