文件操作 - hash.js
返回文件管理
返回主菜单
删除本文件
文件: /var/www/OLD/node_modules/eslint/lib/cli-engine/hash.js
编辑文件内容
/** * @fileoverview Defining the hashing function in one place. * @author Michael Ficarra */ "use strict"; //------------------------------------------------------------------------------ // Requirements //------------------------------------------------------------------------------ const murmur = require("imurmurhash"); //------------------------------------------------------------------------------ // Helpers //------------------------------------------------------------------------------ //------------------------------------------------------------------------------ // Private //------------------------------------------------------------------------------ /** * hash the given string * @param {string} str the string to hash * @returns {string} the hash */ function hash(str) { return murmur(str).result().toString(36); } //------------------------------------------------------------------------------ // Public Interface //------------------------------------------------------------------------------ module.exports = hash;
修改文件时间
将文件时间修改为当前时间的前一年
删除文件