mirror of https://github.com/gogits/gogs.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
343 B
15 lines
343 B
// Copyright (c) 2013 GPMGo Members. All rights reserved. |
|
// Use of this source code is governed by a MIT-style |
|
// license that can be found in the LICENSE file. |
|
|
|
package utils |
|
|
|
import ( |
|
"os" |
|
) |
|
|
|
// IsExist returns if a file or directory exists |
|
func IsExist(path string) bool { |
|
_, err := os.Stat(path) |
|
return err == nil || os.IsExist(err) |
|
}
|
|
|