Thanks fenderman11111. But I managed to get the repository working
This is how I did it. First off, I created a local directory, where I store nothing but .deb packages. For me, this was /home/akudewan/repository/debs/
Next, I created a "Packages" file, that holds info to all packages in the repository. To do this, I used the command:
Code:
dpkg-scanpackages /home/akudewan/repository/debs/ /dev/null > /home/akudewan/repository/debs/Packages
Now, I created a backup of my apt sources, just incase.
Code:
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
Next, edit the /etc/apt/sources.list file and add the line:
Code:
deb file:///home/akudewan/repository/debs ./
Then I was getting an error when using apt, so I had to do this:
Code:
sudo ln -s /home/akudewan/repository/debs/Packages /var/lib/apt/lists/_home_akudewan_repository_debs_._Packages
(Note: Just use underscores(_) instead of / and link your Packages file)
When I ran synaptic after this, everything was working file. But I noticed that the "Packages" file has to be updated whenever you add new packages. So I made a shellscript to do this
Code:
sudo gedit /usr/local/bin/deblocalupdt
Put in the line:
Code:
dpkg-scanpackages /home/akudewan/repository/debs/ /dev/null > /home/akudewan/repository/debs/Packages
Make the file executable:
Code:
sudo chmod a+x /usr/local/bin/deblocalupdt
Now every time I add new packages in the repository, I just have to run "deblocalupdt"
Hurray!