Stop learning alone!

Learn faster and stay on-track by joining this free class with other self-learners.

Register for Learning Vim from the inside now.

Learning Vim from the inside

Open Ended Class

Creator: pbr

Status: Established

Join this class!

Lesson 2: Assignment 2

updating your systems locate database

NOTE to "day one" students: you may not have done this step because I only added it on day 2. Sorry about that. It's really simple though.

We've downloaded a bunch of new tools and pulled the Vim source from the mercurial repository, so it's time to update the system's locate or slocate database:

sudo updatedb

This may take some time to complete depending on when it was last run and how large of a system installation you have.

HOMEWORK: this should be really straightforward. Do NOT submit homework unless something didn't work right for you and you need some help.

Homework Submissions

11 total

shobhitjain (Self-grade: Outstanding)
Submitted 1 week ago | Permalink | Time spent: 1 minute
rainkinz (Self-grade: Outstanding)
Submitted 10 months ago | Permalink | Time spent: 1 minute

Only thing of interest was I needed to sudo updatedb on Ubuntu

brendan@punga:~/code/vim$ updatedb
updatedb: can not open a temporary file for `/var/lib/mlocate/mlocate.db'
brendan@punga:~/code/vim$ sudo updatedb
[sudo] password for brendan: 
brendan@punga:~/code/vim$ locate if_python.c
/home/brendan/code/vim/src/if_python.c
mams827 (Self-grade: Pretty good)
Submitted 1 year ago | Permalink

alredy, to now we go very well, it is easy

listo!, hasta ahora vamos bien, esto esta facil :)

uzziel (Self-grade: Outstanding)
Submitted 1 year ago | Permalink

On OS X it's sudo /usr/libexec/locate.updatedb.

bafbomb (Self-grade: Outstanding)
Submitted 2 years ago | Permalink

updated

popu (Self-grade: Outstanding)
Submitted 2 years ago | Permalink
/mercurial/vim# sudo updatedb
dioltas (Self-grade: Outstanding)
Submitted 2 years ago | Permalink
sgithens (Self-grade: Outstanding)
Submitted 2 years ago | Permalink

no issues here.

thomasmagee (Self-grade: Outstanding)
Submitted 2 years ago | Permalink

Done. I should add that thus far I have been working on a Windows/ Cygwin system, and so far so good.

Comments:

pbr
2 years ago

Outstanding!

I don't see any reason why, with Cygwin, a student on Windows would have any problems with this class. Please do let me know when there are things you have to do differently because of the platform discrepancies. For example, an upcoming assignment will ask about startup script processing; please focus on how it works for your environment and post the details.

Welcome aboard!

Sign up or log in to comment

webframp (Self-grade: Outstanding)
Submitted 2 years ago | Permalink

Done. I think it's a good idea to make a habit of doing this anytime a lot of new files are added to the filesystem

Comments:

pbr
2 years ago

Agreed.

I have an anacron job that runs updatedb for me every day. Might be overkill but hey, it's a computer... it doesn't complain when I give it too much tedious work to do.

pbr
2 years ago

edit: my system has an anacron job that runs updatedb daily. It's now part of Ubuntu. Thinking back, it's been many years since I've had to manually add an 'updatedb' job to cron.

sedrik
2 years ago

anacron is just a cron deamon, the common linux term is cron job =)

pbr
2 years ago

Anacron's quite a bit different than cron. But this isn't a forum for that discussion; the subject here is periodically running updatedb

Welcome aboard; I look forward to your contributions to the source code exploratories.

Sign up or log in to comment

andrewferk (Self-grade: Outstanding)
Submitted 2 years ago | Permalink

I am doing these assignments on a minimal install of Debian 5.0 Lenny, and updatedb was not available. I installed locate, sudo aptitude install locate, then I ran sudo updatedb.

Comments:

pbr
2 years ago

Awesome. I find locate totally necessary; seems a shame people have decided to omit it from 'minimal' distros. I'll guess they left 'find' in, right? By the same logic they should include 'locate'. They each have their purpose.

andrewferk
2 years ago

Yes, 'find' is available on the minimal debian distro.

Sign up or log in to comment