You can use:
sed '/\/as.sh/s/^/#/'
which will replace the zero-width marker of the starting line with a comment symbol for all lines containing /as.sh, as shown in the following example:
pax> echo '
* * * * * sleep 15;/etc/opt/wer.sh
1 * * * * /opt/sfm/qwe/as.sh
' | sed '/\/as.sh/s/^/#/'
* * * * * sleep 15;/etc/opt/wer.sh
#1 * * * * /opt/sfm/qwe/as.sh
But you need to keep in mind a couple of things.
- ,
cron, . , crontab, cron, . - . , , , ( ). .
, :
sed '/\/as.sh/s/^#//'
, , /as.sh, # .