Parse File name in Bash script : <p>I have a filename in a format like:</p>

<pre><code> Master.csv-yyyy-mm-dd.txt
example:- Master.csv.2016-07-06.txt
</code></pre>

<p>I want substring from that in the following format.</p>

<pre><code>  YY-MM
</code></pre>

<p>please help me quickly </p>
