You can generate scriptof the stored proc's as depicted in other answers. Once the script have been generated, you can use sqlcmd
to execute them against target DB like
sqlcmd -S <server name> -U <user name> -d <DB name> -i <script file> -o <output log file>