change indexname if stdin is used for input

closes #368