Skip to content

Commit 09f00b7

Browse files
committed
add mysql script
1 parent dd9594f commit 09f00b7

1 file changed

Lines changed: 38 additions & 0 deletions

File tree

script.sql

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
CREATE TABLE `gitcache_repos` (
2+
`Id` int(11) NOT NULL AUTO_INCREMENT,
3+
`name` varchar(100) NOT NULL DEFAULT '',
4+
`path` varchar(255) NOT NULL DEFAULT '',
5+
`ctime` timestamp NULL DEFAULT NULL,
6+
`utime` timestamp NULL DEFAULT NULL,
7+
`hitcount` int(11) DEFAULT '0',
8+
`tcount` int(11) NOT NULL DEFAULT '10',
9+
`starcount` int(11) DEFAULT '0',
10+
`language` varchar(20) DEFAULT NULL,
11+
`updated_at` timestamp NULL DEFAULT NULL,
12+
`owner` bigint(20) DEFAULT NULL,
13+
`description` varchar(1000) DEFAULT NULL,
14+
`last_recommendtime` bigint(20) DEFAULT '0',
15+
`size` int(11) DEFAULT '0',
16+
PRIMARY KEY (`Id`),
17+
UNIQUE KEY `idx_gitcache_repos` (`path`),
18+
KEY `idx_gitcache_repos1` (`name`),
19+
KEY `idx_gitcache_repos_l` (`last_recommendtime`)
20+
) ENGINE=InnoDB AUTO_INCREMENT=47295 DEFAULT CHARSET=utf8mb4;
21+
22+
CREATE TABLE `gitcache_stats` (
23+
`Id` int(11) NOT NULL AUTO_INCREMENT,
24+
`stime` timestamp NULL DEFAULT NULL,
25+
`cachehit` decimal(10,0) DEFAULT '0',
26+
`redirect` decimal(10,0) DEFAULT '0',
27+
`visit` decimal(10,0) DEFAULT '0',
28+
`vipvisit` decimal(10,0) DEFAULT '0',
29+
`search` decimal(10,0) DEFAULT '0',
30+
`imagetest` decimal(10,0) DEFAULT '0',
31+
`githubapp` decimal(10,0) DEFAULT '0',
32+
`githubdesktop` decimal(10,0) DEFAULT '0',
33+
`githubcli` decimal(10,0) DEFAULT '0',
34+
`gitexe` decimal(10,0) DEFAULT '0',
35+
PRIMARY KEY (`Id`),
36+
UNIQUE KEY `inx_stats_time` (`stime`)
37+
) ENGINE=InnoDB AUTO_INCREMENT=276 DEFAULT CHARSET=utf8mb4;
38+

0 commit comments

Comments
 (0)