Ruby
SQLite and Ruby on Rails
Submitted by Kevin Kleinfelter on Fri, 2007-08-17 17:28.Sqlite DDL
C:\work\rb\test>sqlite db\test.db
SQLite version 2.8.16
Enter ".help" for instructions
sqlite> create table articles
...> (id integer primary key,
...> title varchar(255),
...> text varchar(1024)
...> );
sqlite> .quit
(or create table articles (id integer primary key, title varchar(255), text varchar(1024) );
C:\work\rb\test>dir db
Volume in drive C has no label.
Directory of C:\work\rb\test\db
14.04.2005 14:14 4 096 test.db
Building a Ruby Extension With Win32, Windows XP, in May 2007
Submitted by Kevin Kleinfelter on Fri, 2007-05-25 01:21.When I Googled for building Ruby extensions for Windows, I found a lot of old (very old) information. I found some good info at this web site. What follows is a record of my attempts to follow this guidance.
Bake-off Code 2 Pseduo-code
Submitted by Kevin Kleinfelter on Thu, 2007-05-03 20:13.Plan for failure:
It isn't going to work the first time. In fact, I'm probably not going to successfully complete the login sequence. So just to make sure I understand it correctly, I'll prototype it with wget.
wget \
--no-check-certificate \
--server-response \
--post-data='Passwd=mypass&source=testsrcEmail=me@gmail.com&service=cl' \
--header='Content-Type: application/x-www-form-urlencoded' \
'https://www.google.com/accounts/ClientLogin'
Bake-off Top Level Design
Submitted by Kevin Kleinfelter on Thu, 2007-05-03 20:13.Create a routine that creates a Google data session and an Outlook data session
Retrieve each calendar (is-a or has-a array of events)
Merge the two calendars into a single (new) calendar
GoogleCalendar = mergedCalendar
OutlookCalendar = mergedCalendar
GoogleCalendar.persist
OutlookCalendar.persist
Planned Unit Tests for Bake-off Code 2
Submitted by Kevin Kleinfelter on Thu, 2007-05-03 20:08.I'll need 'session' objects for both Google and Outlook. Sessions can do the following:
- Start-up
- Shut-down
- Give me the full calendar
- Make the full calendar look like this
I'm deliberately keeping sessions as stupid as possible. -------------------------------------------- OBSOLETE CONTENT FOLLOWS
Now I'll begin to flesh out Calendar.merge. For starters, I'll create an AbstractCalendar class and specialize it into GoogleCalendar and OutlookCalendar. Calendars will support the following methods (for now):
- load
- merge
Why Do a Bake-off?
Submitted by Kevin Kleinfelter on Thu, 2007-05-03 20:00.There are several programming languages that interest me lately:
