I'm using VS2015 and I'm generating a Nuget package out of some C# projects I have.
I'm using this line as my post build step:
nuget.exe pack $(ProjectDir)myproj.csproj -Version 0.1.0 -OutputDirectory $(SolutionDir)
You would first need to obtain the version in a separate step (nuget has no concept of loading files for version numbers)
So to get the assemblyinfo of one of your DLLs/exe's you could do something like this:
for /F "tokens=4" %%F in ('filever.exe /B /A /D bin\debug\myproj.dll') do ( set VERSION=%%F )
You could get the version from a text file similarly by doing the following:
for /f "tokens=1" %%F in (version.txt) do set VERSION=%%F