May one run a program or script (or other machine) that will remain inactive (except for a timer, of course) that waits until a certain time on Shabbos/Yom Tov and then performs a function that would not be possible on a weekday? Would there be a difference if it could be done on any day, but it just happens to be Shabbos? If yes, could one then benefit from that operation on Shabbos, e.g. a coffee-maker?
I read this response (update: the link is dead, but the suggestion was to write a script to visit SE on Shabbos in order to earn the enthusiast and fanatic badges) and while I think that that suggestion may be dishonest, it is an interesting question.
In summary then, there are several questions:
- May one leave a device, mechanical or computerized, running on Shabbos. (This is asked in another question (below), but the answer doesn't bring any contemporary sources)
- What if one benefits from said device on Shabbos itself? (Lights, coffee, TV?)
- What if the function performed can only be performed on Shabbos specifically? (Fanatic badge)
- Is Maaras Ayin* the only concern?
Please include (contemporary) sources where applicable.
Related: Computer working on Shabbos
*Maaras Ayin is the concern that others will think you are doing/have done something that actually is forbidden, but they will think that because you have done it, it must be alright. In this case, people will think that I have visted the site on Shabbbos (which is forbidden), and will conclude that visiting the site on Shabbos isn't forbidden at all, "after all", they'll say, "HodofHod did it!".
Update: While YDK's answer is very good, I'd like to see someone even more contemporary than R' Moshe address this question, especially regarding computers, which could be different than timers. Also, R' Moshe's teshuva doesn't cover a case where there is no benefit/interaction with the device until after Shabbos.