I'm trying to create a deb package using fpm, which contains some shell script files.But the deb package should create with a dependency called vim(vim editor in Linux). Means when installing deb package it should install vim first and then script files.
Requirement is when installing deb package the vim should install first and then script files.
The fpm command I have tried is :
fpm -s dir -t deb -n 'test' --deb-pre-depends vim --after-install /home/test/testfile.sh -C /home test
And after deb package created. when installing it, I'm getting following errors:
dpkg: regarding test_1.0_amd64.deb containing test, pre-dependency problem:
test pre-depends on vim
vim is not installed.
dpkg: error processing archive test_1.0_amd64.deb (--install):
pre-dependency problem - not installing test
Errors were encountered while processing:
test_1.0_amd64.deb
Thanks in Advance...
try --depends instead of --deb-pre-depends
"Depend" and "Pre Depend" are subtly different see here https://www.debian.org/doc/debian-policy/ch-relationships.html
Sounds like what you want to do is probably "Depend" so keep it simple