Pour 3 cups of water and 1 1/2 cups of rice into rice cooker. Cook as per your rice cooker's instructions.
While the rice is cooking, saute the onions in the oil on medium heat until translucent. Add the minced garlic and saute for another two minutes, carefully watching so the garlic doesn't burn. Set aside.
When rice is done cooking, stir in the cooked garlic and onions. Add the lime juice and the cilantro. Season with salt and pepper.