func self() (string, error) {
	bin := os.Args[0]
	if !filepath.IsAbs(bin) {
		var err error
		bin, err = os.Executable()
		if err != nil {
			return "", fmt.Errorf(
				"cannot get path to binary %q (launch with absolute path): %w",
				os.Args[0], err)
		}
	}
	return bin, nil
}
// Get location to executable.
Get location to executable.
// Get location to executable .
func self() (string, error) {
	bin := os.Args[0]
	if !filepath.IsAbs(bin) {
		var err error
		bin, err = os.Executable()
		if err != nil {
			return "", fmt.Errorf(
				"cannot get path to binary %q (launch with absolute path): %w",
				os.Args[0], err)
		}
	}
	return bin, nil
}
func self ( ) ( string , error ) { bin := os . Args [ 0 ] if ! filepath . IsAbs ( bin ) { var err error bin , err = os . Executable ( ) if err != nil { return " " , fmt . Errorf ( " " , os . Args [ 0 ] , err ) } } return bin , nil }
Get location to executable.
Get location to executable .