aboutsummaryrefslogtreecommitdiff
path: root/models/repo.go
diff options
context:
space:
mode:
authorUnknown <joe2010xtmf@163.com>2014-03-02 15:25:14 -0500
committerUnknown <joe2010xtmf@163.com>2014-03-02 15:25:14 -0500
commit3f849ddfabbbbf77f66a18e0d88ba97a132f9812 (patch)
tree7f8365149c91ebc81c83c0767b3f51d53cc57de3 /models/repo.go
parente9487cb59cb7fcdc8891ccae93c33c9f587c576f (diff)
parent71bae3ebd37e20130131328923dbff2de35093b6 (diff)
Merge branch 'master' of github.com:gogits/gogs
Diffstat (limited to 'models/repo.go')
-rw-r--r--models/repo.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/models/repo.go b/models/repo.go
index 70e2673d..6fc59056 100644
--- a/models/repo.go
+++ b/models/repo.go
@@ -27,6 +27,13 @@ type Repo struct {
Updated time.Time `xorm:"updated"`
}
+type Star struct {
+ Id int64
+ RepoId int64
+ UserId int64
+ Created time.Time `xorm:"created"`
+}
+
// check if repository is exist
func IsRepositoryExist(user *User, reposName string) (bool, error) {
repo := Repo{OwnerId: user.Id}
@@ -121,6 +128,10 @@ func UnWatchRepository() {
}
+func ForkRepository(reposName string, userId int64) {
+
+}
+
func RepoPath(userName, repoName string) string {
return filepath.Join(UserPath(userName), repoName+".git")
}