Skip to main content
2 of 2
added 669 characters in body
Dennis
  • 210.6k
  • 41
  • 370
  • 825

CJam, 18 bytes

ea_:gs{q}?'_,_eler

The list of files must be supplied in form of URLs, which is the only format CJam understands.

Example runs

$ cjam kitten <<< "AaÁáÄä"
aaÁáÄä
$ cjam kitten file:///home/dennis/kitten file:///home/dennis/kitten
ea_:gs{q}?'_,_elerea_:gs{q}?'_,_eler

How it works

ea                  Push the array of command-line arguments.
  _                 Push a copy.
   :g               Retrieve the contents of all files with those URLS.
     s              Flatten the resulting array of strings.
      {q}           Push a block that reads all input from STDIN.
         ?          Select the string of the array of args is non-empty.
                    Otherwise, execute the code block.
          '_,       Push the string of all ASCII characters before _.
             _el    Push a copy and convert it to lowercase.
                er  Perform transliteration.
Dennis
  • 210.6k
  • 41
  • 370
  • 825