Is there any way of just unlocking accounts without opening the console with `geth`?

I'm writing some scripts to automate cluster generation and I wish I could just call `geth` to unlocking some accounts without starting another instance or attaching to an existing one.

---

##Edit
If I run something like:

    geth --genesis "$GENESIS_FILE" --datadir "$DATA_DIR" --networkid "$NETWORK_ID" \
         --password <(echo -n $ACCOUNT_PASSWD) --unlock "$UNLOCK_INDEXES" \
         --exec '""' attach > /dev/null

after the node startup, the **accounts are not unlocked**.

The only way I've managed to get accounts unlocked was to unlock them when running `geth` in order to start the node.