If you use two or more partitions on your computer, for example:
/ ( partition for system, small partition, at my place 20 GB)
/home (partition for user data, big partition, at my place 200 GB)
Sources do not come into /var/lib/jenkins. Therefore, you need a few odd tricks.
I have a source in /home/maxprzemo/CM13
Jenkins working directory is /var/lib/jenkins/jobs/CM13/workspace
Make an empty folder with the name CM13 (rename the CM13 on your folder name)
sudo mkdir /var/lib/jenkins/jobs/CM13/workspace/CM13
mount in this folder sources (replace "maxprzemo" on the name of your user)
sudo mount -o bind /home/maxprzemo/CM13 /var/lib/jenkins/jobs/CM13/workspace/CM13
sudo chown -R jenkins:jenkins /var/lib/jenkins/jobs/CM13/workspace/CM13
For automatic mounting at startup add to file etc/init.d/jenkins
(replace "maxprzemo" on the name of your user)
mount -o bind /home/maxprzemo/CM13 /var/lib/jenkins/jobs/CM13/workspace/CM13
To work correctly "repo sync"add to your script .sh (replace "maxprzemo" on the name of your user)
It may be useful to someone.