rolloverarchivebot.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:abusehelper 作者: Exploit-install 项目源码 文件源码
def current_timestamp(timestamp, period):
    time_list = list(time.gmtime())
    period = period.lower()

    if period == "day":
        time_list[3:] = [0] * 6
    elif period == "month":
        time_list[2:] = [1] + [0] * 6
    elif period == "week":
        time_list[2] -= time_list[6]
        time_list[3:] = [0] * 6
    elif period == "year":
        time_list[1:] = [1, 1] + [0] * 6
    else:
        return None

    return time.gmtime(calendar.timegm(time_list))
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号