You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
491 B
Bash

#!/bin/bash
# fanta <fanta@56k.es>
# Helper script to find words in the spanish worlde version
wordList="words-es.txt"
function showError(){
echo "[Error] $1"
}
if [ -z "$1" ]; then
showError "Example: wordle.sh n..io (The dots are the unknown characters)"
else
if [ $(echo -n "$1" | wc -m) -le 5 ]; then
grep -iEw "$1" $wordList
# la salida tendria que ser de palabras solamente con 5 caracteres
else
showError "Too many characters my friend. They must be 5"
fi
fi