Skip to content

Instantly share code, notes, and snippets.

@weskerty
Last active March 16, 2025 01:49
Show Gist options
  • Save weskerty/a4899a95d5f7674d327ecc9221081cbd to your computer and use it in GitHub Desktop.
Save weskerty/a4899a95d5f7674d327ecc9221081cbd to your computer and use it in GitHub Desktop.
// adaptado de: https://github.com/BrunoSobrino/TheMystic-Bot-MD/blob/master/plugins/herramientas-readmore.js
const { bot } = require('../lib');
const more = String.fromCharCode(8206);
const readMore = more.repeat(4001);
bot(
{
pattern: 'readmore ?(.*)',
desc: 'Add Readmore Hi|Readmore',
type: 'misc',
},
async (message, match) => {
if (!match) {
return await message.send('Example : readmore Hi readmore hello');
}
const readmoreText = match.replaceAll('readmore', readMore);
try {
await message.send(readmoreText);
} catch (error) {
console.error('Error en readmore:', error);
await message.send('❌ Error.');
}
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment