Print first element of the last line of files when the second element does not match a pattern
That second grep (grep -v 'fitness') is there to filter out the filenames that tail spits out, right? That can be removed by using the -q option for tail.

Personally, I'd try to avoid that paste command, but that might just be because I'm not used to it. If you don't need spaces after the commas, tr works just fine.

tail -qn 1 *fitness* | grep -v '100000' | awk '{print $1}' | grep -v '^$' | tr '\n' ','


Now, since you're already using awk, why not do a bit more with it (actually, the whole thing could probably be made into an awk program with either more time or more experience than I have available)?

This uses a single awk statement to choose only lines that don't contain the word '100000' and also have a non-empty first field, and also to print that first field. What it does for readability depends on personal preference, but it certainly reduces the number of programs that need to be chained together:

tail -qn 1 *fitness* | awk '(! /\&lt;100000\&gt;/) &amp;&amp; $1 !~ /^$/ {print $1}' | tr '\n' ','