mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-20 21:44:48 +02:00
Sha1 Command
This commit is contained in:
@@ -15,7 +15,7 @@ Xiao is a Discord bot coded in JavaScript with
|
|||||||
The bot is no longer available for invite. You can self-host the bot, or use her
|
The bot is no longer available for invite. You can self-host the bot, or use her
|
||||||
on the [home server](https://discord.gg/sbMe32W).
|
on the [home server](https://discord.gg/sbMe32W).
|
||||||
|
|
||||||
## Commands (321)
|
## Commands (322)
|
||||||
### Utility:
|
### Utility:
|
||||||
|
|
||||||
* **eval:** Executes JavaScript code.
|
* **eval:** Executes JavaScript code.
|
||||||
@@ -328,6 +328,7 @@ on the [home server](https://discord.gg/sbMe32W).
|
|||||||
* **repeat:** Repeat text over and over and over and over (etc).
|
* **repeat:** Repeat text over and over and over and over (etc).
|
||||||
* **reverse:** Reverses text.
|
* **reverse:** Reverses text.
|
||||||
* **say:** Make me say what you want, master.
|
* **say:** Make me say what you want, master.
|
||||||
|
* **sha-1:** Creates a hash of text with the SHA-1 algorithm.
|
||||||
* **sha-256:** Creates a hash of text with the SHA-256 algorithm.
|
* **sha-256:** Creates a hash of text with the SHA-256 algorithm.
|
||||||
* **ship-name:** Creates a ship name from two names.
|
* **ship-name:** Creates a ship name from two names.
|
||||||
* **shorten-url:** Creates a goo.gl short URL from another URL.
|
* **shorten-url:** Creates a goo.gl short URL from another URL.
|
||||||
|
|||||||
@@ -0,0 +1,25 @@
|
|||||||
|
const Command = require('../../structures/Command');
|
||||||
|
const { hash } = require('../../util/Util');
|
||||||
|
|
||||||
|
module.exports = class SHA1Command extends Command {
|
||||||
|
constructor(client) {
|
||||||
|
super(client, {
|
||||||
|
name: 'sha-1',
|
||||||
|
aliases: ['sha-1-hash'],
|
||||||
|
group: 'text-edit',
|
||||||
|
memberName: 'sha-1',
|
||||||
|
description: 'Creates a hash of text with the SHA-1 algorithm.',
|
||||||
|
args: [
|
||||||
|
{
|
||||||
|
key: 'text',
|
||||||
|
prompt: 'What text would you like to create an SHA-1 hash of?',
|
||||||
|
type: 'string'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
run(msg, { text }) {
|
||||||
|
return msg.say(hash(text, 'sha1'));
|
||||||
|
}
|
||||||
|
};
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "xiao",
|
"name": "xiao",
|
||||||
"version": "92.0.0",
|
"version": "92.1.0",
|
||||||
"description": "Your personal server companion.",
|
"description": "Your personal server companion.",
|
||||||
"main": "Xiao.js",
|
"main": "Xiao.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
Reference in New Issue
Block a user