92 lines
1.5 KiB
Python
92 lines
1.5 KiB
Python
|
||
from connect import *
|
||
|
||
"""
|
||
输入:项目id
|
||
输出:该项目该行为的次数
|
||
"""
|
||
|
||
#Add lines of code(CADD)
|
||
def CADD_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Remove lines of code(CREM)
|
||
def CREM_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Commit new source file(CNS)
|
||
def CNS_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Commit new directory(CND)
|
||
def CND_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Commit more than X files in a single commit(CMF)
|
||
def CMF_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Commit documentation files(CDF)
|
||
def CDF_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Commit translation files(CTF)
|
||
def CTF_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Commit binary files(CBF)
|
||
def CBF_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#First reply to thread(MFR)
|
||
def MFR_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Start a new thread(MST)
|
||
def MST_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Close a lingering thread(MCT)
|
||
def MCT_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Start a new wiki page(WSP)
|
||
def WSP_para(mysql,project_id):
|
||
|
||
wiki_id = mysql.operation('select id from wikis where project_id = '+str(project_id))
|
||
|
||
return len(wiki_id)
|
||
|
||
#Update a wiki page(WUP)
|
||
def WUP_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Frequent participation to IRC(IFP)
|
||
def IFP_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
#Prompt replies to directed questions(IRQ)
|
||
def IRQ_para(mysql,project_id):
|
||
|
||
return 0
|
||
|
||
|
||
if __name__ == "__main__":
|
||
|
||
mysql = Database()
|
||
mysql.connect()
|
||
WSP_para(mysql,2023)
|
||
mysql.disconnect() |