pal-0.4.3/0000755000175000017500000000000011043370327012166 5ustar kleptogkleptogpal-0.4.3/src/0000755000175000017500000000000011043370327012755 5ustar kleptogkleptogpal-0.4.3/src/main.h0000644000175000017500000001216211043370327014054 0ustar kleptogkleptog#ifndef PAL_MAIN_H #define PAL_MAIN_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include #include #include #define _(String) gettext (String) #define gettext_noop(String) String #define N_(String) gettext_noop (String) GDate* get_query_date(gchar* date_string, gboolean show_error); void pal_main_reload(void); /* a structure that contains all of the runtime settings */ typedef struct _Settings { gint cal_lines; /* number of lines for calendar */ gint range_days; /* print events in the next 'range_days' days */ gint range_neg_days; /* print events within 'range_neg_days' days old */ gboolean range_arg; /* user started pal with -r */ gchar* search_string; /* regex to search for */ gboolean verbose; /* verbose output */ GDate* query_date; /* from argument used after -d */ gint expunge; /* expunge events older than 'expunge' days */ gboolean mail; /* --mail */ gchar* conf_file; /* .conf file to use */ gboolean specified_conf_file; /* user specified a .conf file */ gchar* date_fmt; /* format of date to use with -r */ gboolean week_start_monday; /* weeks should start on monday */ gboolean reverse_order; /* show things in reverse order */ gboolean cal_on_bottom; /* show calendar last */ gboolean no_columns; /* don't use columns */ gboolean hide_event_type; /* hide the type of listed events */ gint term_cols; /* number of columns in terminal */ gint term_rows; /* number of rows in terminal */ gboolean manage_events; /* add an event to pal, interactive */ gboolean curses; /* use curses output functions instead of glib */ gint event_color; /* default event color */ gboolean html_out; /* html output */ gboolean latex_out; /* LaTeX output */ gboolean compact_list; /* show a compact list */ gboolean show_weeknum; /* Show weeknum in output */ gchar* compact_date_fmt; /* comapct list date format */ gchar* pal_file; /* specified one pal file to load instead * of those in pal.conf */ } Settings; typedef struct _PalTime { gint hour; gint min; } PalTime; typedef enum _PalPeriodic { PAL_ONCEONLY, PAL_DAILY, PAL_WEEKLY, PAL_MONTHLY, PAL_YEARLY } PalPeriodic; #define MAX_KEYLEN 16 /* Defines event types. Where a string is returned, caller must free */ typedef struct _PalEventType { PalPeriodic period; gboolean (*valid_string)(const gchar *); /* Returns true if this string is valid for this event type */ gboolean (*get_key)(const GDate *, gchar *); /* For the given date, return the key for this event type */ gchar *(*get_descr)(const GDate *); /* For the given date, return a textual representation */ } PalEventType; /* See event.c for definition of PalEventTypes */ extern PalEventType PalEventTypes[]; extern const gint PAL_NUM_EVENTTYPES; /* number of items in PalEventTypes */ typedef struct _PalEvent { gchar* text; /* description of event */ gunichar start; /* character used before the day in calendar */ gunichar end; /* character used after the day in calendar */ gboolean hide; /* should the event be hidden on the calendar? */ gchar* type; /* type of event it is (from top of calendar file) */ gint file_num; /* this event was in the file_num-th file loaded */ gchar* file_name; /* name of the file containing this event */ gint color; /* color to be used with this event */ GDate* start_date; /* for recurring events, date event starts on */ GDate* end_date; /* for recurring events, date event ends on */ PalTime* start_time; /* 1st time listed in event description */ PalTime* end_time; /* 2nd time listed in event description */ gchar* date_string; /* date string used in the file for this event */ gboolean global; /* TRUE if event is in a global file */ gint period_count; /* How often repeat (default=1) */ gchar* key; /* Key in hash table */ PalEventType *eventtype; /* Pointer to eventtype struct */ } PalEvent; extern Settings* settings; extern GHashTable* ht; /* ht holds the loaded events */ #define INTERACT_DAY_RANGE 1825 /* With -m, look for events up to 5 years (ignoring leap days) into the future */ #endif pal-0.4.3/src/latex.c0000644000175000017500000001436311043370327014245 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include #include "main.h" #include "event.h" /* prints out the string but properly escapes things for LaTeX */ static void pal_latex_escape_print(gchar* s) { gunichar c; /* Note: g_print uses the current locale encoding, even though we print UTF-8 */ while( (c = g_utf8_get_char(s)) != '\0') { if(c == '&') /* & to \& */ g_print("\\&"); else if(c == '$') /* $ to \$ */ g_print("\\$"); else if(c == '\\') /* \ to \\ */ g_print("\\\\"); else if(c == '}') /* } to \} */ g_print("\\}"); else if(c == '{') /* { to \{ */ g_print("\\{"); else if(c == '#') /* # to \# */ g_print("\\#"); else if(c == '%') /* % to \% */ g_print("\\%%"); else if(c == '^') /* ^ to \^ */ g_print("\\^"); else if(c == '_') /* _ to \_ */ g_print("\\_"); else if(c >= 32 && c < 128) g_print("%c", c); else g_print("\\unichar{%d}", c); /* print 1 char */ s = g_utf8_next_char(s); } } /* finishes with date on the first day in the next month */ static void pal_latex_month(GDate* date, gboolean force_month_label) { gint i; gchar buf[1024]; gint orig_month = g_date_get_month(date); g_date_strftime(buf, 1024, "%B %Y", date); g_print("%s%s%s", "\\textbf{\\Large ", buf, "}\n"); g_print("%s", "\\smallskip\n"); g_print("%s", "\\begin{tabularx}{10.0in}{|p{1.26in}|p{1.26in}|p{1.26in}|p{1.26in}|p{1.26in}|p{1.26in}|p{1.24in}|}\n"); g_print("%s", "\\hline\n"); if(!settings->week_start_monday) g_print("%s%s%s&", "\\textbf{", _("Sunday"), "}"); g_print("%s%s%s&", "\\textbf{", _("Monday"), "}"); g_print("%s%s%s&", "\\textbf{", _("Tuesday"), "}"); g_print("%s%s%s&", "\\textbf{", _("Wednesday"), "}"); g_print("%s%s%s&", "\\textbf{", _("Thursday"), "}"); g_print("%s%s%s&", "\\textbf{", _("Friday"), "}"); g_print("%s%s%s", "\\textbf{", _("Saturday"), "}"); if(settings->week_start_monday) g_print("&%s%s%s", "\\textbf{", _("Sunday"), "}"); g_print("\\\\\n"); g_print("\\hline \\hline\n"); /* start the month on the right weekday */ if(settings->week_start_monday) for(i=0; i num_events_printed) { gchar* event_text = pal_event_escape((PalEvent*) (item->data), date); g_print("$\\cdot$"); pal_latex_escape_print(event_text); g_print("\n\n"); num_events_printed++; item = g_list_next(item); g_free(event_text); } g_print("}"); if(num_events == 0) g_print("\\vspace{.9in}"); else g_print("\\vspace{.3in}"); if((settings->week_start_monday && g_date_get_weekday(date) == 7) || (!settings->week_start_monday && g_date_get_weekday(date) == 6)) { if(!g_date_is_last_of_month(date)) g_print("\\\\ \\hline\n"); else g_print("\n"); } else g_print (" &\n"); g_date_add_days(date,1); g_list_free(events); } /* skip to end of calendar */ if(settings->week_start_monday) { int tmp = g_date_get_weekday(date); if(tmp == 1) tmp = 7; while(tmp != 7) { g_print(" & "); tmp++; } } else { int tmp = g_date_get_weekday(date); if(tmp == 7) tmp = 6; while(tmp != 6) { g_print(" & "); tmp++; } } g_print("\\\\ \\hline \\end{tabularx}\n"); } void pal_latex_out(void) { gint on_month = 0; GDate* date = g_date_new(); if( settings->query_date ) memcpy( date, settings->query_date, sizeof(GDate) ); else g_date_set_time_t(date, time(NULL)); g_print("%s%s\n", "% Generated with pal ", PAL_VERSION); g_print("%s", "\\documentclass[12pt]{article}\n"); g_print("%s", "\\usepackage{lscape}\n"); g_print("%s", "\\usepackage{tabularx}\n\n"); g_print("%s", "%% Uncomment this line if you want you have unicode output\n"); g_print("%s", "%%\\usepackage{ucs}\n"); g_print("%s", "\\setlength{\\hoffset}{-.5in}\n"); g_print("%s", "\\setlength{\\oddsidemargin}{0in}\n"); g_print("%s", "\\setlength{\\evensidemargin}{0in}\n"); g_print("%s", "\\setlength{\\voffset}{-.5in}\n"); g_print("%s", "\\setlength{\\topmargin}{0in}\n"); g_print("%s", "\\setlength{\\headheight}{0in}\n"); g_print("%s", "\\setlength{\\headsep}{0in}\n"); g_print("%s", "\\setlength{\\textheight}{10in}\n"); g_print("%s", "\\setlength{\\textwidth}{7.5in}\n"); g_print("%s", "\\setlength{\\marginparwidth}{0in}\n"); g_print("%s", "\\setlength{\\marginparsep}{0in}\n\n"); g_print("%s", "\\pagestyle{empty}\n"); g_print("%s", "\\parindent=0pt\n\n"); g_print("%s", "\\begin{document}\n"); g_print("%s", "\\begin{landscape}\n\n"); g_print("%s", "\\begin{center}\n\n"); /* back up to the first of the month */ g_date_subtract_days(date, g_date_get_day(date) - 1); for(on_month=0; on_month < settings->cal_lines; on_month++) { if(on_month != 0) g_print("%s", "\\newpage\n"); pal_latex_month(date, TRUE); } g_print("%s", "\n\\end{center}\n"); g_print("%s", "\\end{landscape}\n"); g_print("%s", "\\end{document}\n"); } pal-0.4.3/src/latex.h0000644000175000017500000000151511043370327014245 0ustar kleptogkleptog#ifndef PAL_LATEX_H #define PAL_LATEX_H /* pal * * Copyright (C) 2003, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ void pal_latex_out(void); #endif pal-0.4.3/src/output.h0000644000175000017500000000267411043370327014477 0ustar kleptogkleptog#ifndef PAL_OUTPUT_H #define PAL_OUTPUT_H /* pal * * Copyright (C) 2003, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include "main.h" #include "colorize.h" void pal_output_handler( const gchar *instr ); void pal_output_attr(gint attr, gchar *formatString, ...); void pal_output_fg(gint attr, gint color, gchar *formatString,...); void pal_output_error(char *formatString, ... ); void pal_output_cal(gint num_weeks, GDate* today); int pal_output_date(GDate* date, gboolean show_empty_days, gint select_event); void pal_output_date_line(GDate* date); int pal_output_event(PalEvent* event, GDate* date, gboolean selected); int pal_output_wrap(const gchar* string, gint chars_used, gint indent); PalEvent* pal_output_event_num(const GDate* date, gint event_number); #endif pal-0.4.3/src/del.c0000644000175000017500000000670711043370327013677 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include #include "main.h" #include "output.h" #include "event.h" #include "rl.h" #include "input.h" #include "edit.h" void pal_del_write_file(PalEvent* dead_event) { FILE *file = NULL; gchar* filename = g_strdup(dead_event->file_name); FILE *out_file = NULL; gchar *out_filename = NULL; PalEvent* event_head = NULL; g_strstrip(filename); out_filename = g_strconcat(filename, ".paltmp", NULL); file = fopen(filename, "r"); if(file == NULL) { pal_output_error(_("ERROR: Can't read file: %s\n"), filename); pal_output_error(_(" The event was NOT deleted.")); return; } out_file = fopen(out_filename, "w"); if(out_file == NULL) { pal_output_error(_("ERROR: Can't write file: %s\n"), out_filename); pal_output_error(_(" The event was NOT deleted.")); if(file != NULL) fclose(file); return; } pal_input_skip_comments(file, out_file); event_head = pal_input_read_head(file, out_file, filename); while(1) { PalEvent* pal_event = NULL; pal_input_skip_comments(file, out_file); pal_event = pal_input_read_event(file, out_file, filename, event_head, dead_event); /* stop trying to delete dead_event if we just deleted it */ if(dead_event != NULL && pal_event == dead_event) dead_event = NULL; else if(pal_event == NULL && pal_input_eof(file)) break; } fclose(file); fclose(out_file); if(rename(out_filename, filename) != 0) { pal_output_error(_("ERROR: Can't rename %s to %s\n"), out_filename, filename); pal_output_error(_(" The event was NOT deleted.")); return; } if(dead_event == NULL) { pal_output_fg(BRIGHT, GREEN, ">>> "); g_print(_("Event removed from %s.\n"), filename); } else pal_output_error(_("ERROR: Couldn't find event to be deleted in %s"), filename); g_free(filename); } static void pal_del_event( GDate *date, int eventnum ) { PalEvent* dead_event = NULL; GDate* event_date = NULL; clear(); pal_output_fg(BRIGHT, GREEN, "* * * "); pal_output_attr(BRIGHT, _("Delete an event")); pal_output_fg(BRIGHT, GREEN, " * * *\n"); pal_output_fg(BRIGHT, YELLOW, "> "); pal_output_wrap(_("If you want to delete old events that won't occur again, you can use pal's -x option instead of deleting the events manually."),2,2); dead_event = pal_rl_get_event(&event_date, FALSE); g_print("\n"); pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("You have selected to delete the following event:\n")); pal_output_event(dead_event, event_date, -1); if(pal_rl_get_y_n(_("Are you sure you want to delete this event? [y/n]: "))) pal_del_write_file(dead_event); pal_main_reload(); } pal-0.4.3/src/rl.c0000644000175000017500000002272311043370327013544 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include "main.h" #include #include #include #include #include "output.h" #include "rl.h" #include "event.h" #include "search.h" static gint readline_x, readline_y; char* pal_rl_default_text = NULL; char* pal_rl_no_match() { return NULL; } void pal_rl_default_text_fn(void) { gchar* locale_default_text = g_locale_from_utf8(pal_rl_default_text, -1, NULL, NULL, NULL); if(locale_default_text == NULL) rl_insert_text(pal_rl_default_text); /* this shouldn't happen */ else { rl_insert_text(locale_default_text); g_free(locale_default_text); } rl_redisplay_function(); } /* prompt for required input, including blank lines */ /* caller is responsible for freeing the prompt and the read line */ gchar* pal_rl_get_raw_line(const char* prompt, const int row, const int col) { char *line = NULL; char *locale_prompt = NULL; locale_prompt = g_locale_from_utf8(prompt, -1, NULL, NULL, NULL); readline_x = col + strlen( locale_prompt ); readline_y = row; if(locale_prompt == NULL) line = readline(prompt); /* this shouldn't happen */ else { move(row, col); clrtoeol(); move(row,col); pal_output_fg(BRIGHT, GREEN, "%s", prompt); refresh(); line = readline(""); refresh(); /* need refresh to prevent screen from getting * messed up when user presses enter */ g_free(locale_prompt); } if(line == NULL) /* line is null with ^D */ exit(0); g_strstrip(line); /* try to convert to utf8 if it isn't ascii or utf8 already. */ if(!g_utf8_validate(line, -1, NULL)) { gchar* utf8_string = g_locale_to_utf8(line, -1, NULL, NULL, NULL); if(utf8_string == NULL) { pal_output_error(_("WARNING: Failed to convert your input into UTF-8.\n")); return line; } else { if(settings->verbose) g_printerr("%s\n", _("Converted string to UTF-8.")); g_free(line); return utf8_string; } } return line; } /* Calls pal_rl_get_raw_line, but ignores empty input */ gchar* pal_rl_get_line(const char* prompt, const int row, const int col) { gchar *line = NULL; do { if( line ) g_free(line); line = pal_rl_get_raw_line(prompt, row, col); } while( *line == '\0' ); return line; } gchar* pal_rl_get_line_default(const char* prompt, const int row, const int col, const char* default_text) { gchar* desc = NULL; if( default_text == NULL ) default_text = ""; pal_rl_default_text = strdup(default_text); rl_pre_input_hook = (rl_hook_func_t*) pal_rl_default_text_fn; desc = pal_rl_get_line(prompt, row, col); g_free(pal_rl_default_text); rl_pre_input_hook = NULL; return desc; } /* Displays completions */ void pal_rl_completions_output(char **matches, int num_matches, int max_length ) { int matches_per_line; int matchlen = strlen( matches[0] ); int i; int y,x; getyx( stdscr, y, x ); max_length += 2; /* Two spaces between lists */ matches_per_line = settings->term_cols / max_length; move( y+1, 0 ); clrtobot(); for( i=0; iterm_cols - readline_x) / 2 - 3; int start, end; move(readline_y, readline_x); clrtoeol(); move(readline_y, readline_x); /* Move back to the nearest "half" boundary and another block. If we go * past the start of the string, reset to the start */ start = rl_point - (rl_point % half) - half; if( start < 0 ) start = 0; /* Determine where the screen can print upto. If the string ends first, * don't worry about it. */ end = start + settings->term_cols - readline_x - 2; if( end > strlen( rl_line_buffer ) ) end = -1; /* If we're not starting at the beginning, display marker */ if( start > 0 ) addch( '<' ); /* Display string, including marker if went off end */ if( end > 0 ) printw( "%.*s>", end - start, rl_line_buffer + start); else printw( "%s", rl_line_buffer + start ); /* Place cursor, taking into account marker */ move(readline_y, readline_x + rl_point - start + (start > 0) ); refresh(); } gboolean pal_rl_get_y_n(const char* prompt) { gchar *s = NULL; int y, x; getyx( stdscr, y, x ); for(;;) { rl_num_chars_to_read = 1; s = pal_rl_get_line(prompt, y, x); rl_num_chars_to_read = 0; if(g_ascii_strcasecmp(s, _("y")) == 0) { g_free(s); return TRUE; } else if(g_ascii_strcasecmp(s, _("n")) == 0) { g_free(s); return FALSE; } g_free(s); } } /* d gets filled in with GDate entered by the user to find the PalEvent. */ PalEvent* pal_rl_get_event(GDate** d, gboolean allow_global) { gchar* s = NULL; PalEvent* event = NULL; *d = NULL; while(1) { pal_output_fg(BRIGHT, YELLOW, "> "); pal_output_wrap(_("Use \"today\" to access TODO events."),2,2); pal_output_fg(BRIGHT, GREEN, "> "); pal_output_wrap(_("Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away"),2,2); s = pal_rl_get_line(_("Date for event or search string: "), settings->term_rows-2, 0); *d = get_query_date(s, FALSE); if(*d != NULL) { gint event_num = -1; g_print("\n"); pal_output_date(*d, TRUE, -1); g_print("\n"); { /* Don't allow user select a day without events on it */ GList* events = get_events(*d); gint num_events = g_list_length(events); if(num_events==0) continue; } while(1) { pal_output_fg(BRIGHT, YELLOW, "> "); pal_output_wrap(_("Use \"0\" to use a different date or search string."),2,2); s = pal_rl_get_line(_("Select event number: "),settings->term_rows-2,0); if(strcmp(s, "0") == 0) return pal_rl_get_event(d, allow_global); if(sscanf(s, "%i", &event_num) != 1) continue; event = pal_output_event_num(*d, event_num); if(event != NULL) { if(!event->global || allow_global) return event; pal_output_fg(BRIGHT, RED, "> "); pal_output_wrap(_("This event is in a global calendar file. You can change this event only by editing the global calendar file manually (root access might be required)."),2,2); } } } else /* d == NULL */ { gchar* search_string = g_strdup(s); gint event_num = -1; GDate* date = g_date_new(); g_date_set_time_t(date, time(NULL)); if(pal_search_view(search_string, date, 365, TRUE) == 0) continue; while(1) { pal_output_fg(BRIGHT, YELLOW, "> "); pal_output_wrap(_("Use \"0\" to use a different date or search string."),2,2); s = pal_rl_get_line(_("Select event number: "),settings->term_rows-2,0); if(strcmp(s, "0") == 0) return pal_rl_get_event(d, allow_global); if(sscanf(s, "%i", &event_num) != 1) continue; event = pal_search_event_num(event_num, d, search_string, date, 365); if(event != NULL) { if(!event->global || allow_global) return event; pal_output_fg(BRIGHT, RED, "> "); pal_output_wrap(_("This event is in a global calendar file. You can change this event only by editing the global calendar file manually (root access might be required)."),2,2); } } g_free(search_string); } if(*d != NULL) g_date_free(*d); if(s != NULL) g_free(s); } /* end while(1); */ /* impossible */ return NULL; } #if 0 /* Returns the hashtable key for the day that the user inputs. The * user can select a TODO event by entering TODO for the date. */ static gchar* pal_rl_get_date(int row, int col) { gchar* s = NULL; GDate* d = NULL; do { move( row, col ); pal_output_fg(BRIGHT, GREEN, "> "); pal_output_wrap(_("Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away"),2,2); s = pal_rl_get_line(_("Date for event: "),row+2,0); d = get_query_date(s, FALSE); if(d != NULL) { gchar buf[1024]; g_print("\n"); pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("Events on the date you selected:\n")); g_print("\n"); pal_output_date(d, TRUE, -1); g_print("\n"); pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("Is this the correct date?")); g_print("\n"); g_date_strftime(buf, 1024, _("%a %e %b %Y - Accept? [y/n]: "), d); if(pal_rl_get_y_n(buf)) { s = get_key(d); g_date_free(d); return s; } } else { if(g_ascii_strcasecmp(s, "todo") == 0) return g_strdup("TODO"); } if(d != NULL) g_date_free(d); if(s != NULL) g_free(s); } while(1); /* impossible */ return NULL; } #endif pal-0.4.3/src/html.h0000644000175000017500000000151211043370327014071 0ustar kleptogkleptog#ifndef PAL_HTML_H #define PAL_HTML_H /* pal * * Copyright (C) 2003, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ void pal_html_out(void); #endif pal-0.4.3/src/input.h0000644000175000017500000000225311043370327014267 0ustar kleptogkleptog#ifndef PAL_INPUT_H #define PAL_INPUT_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ GHashTable* load_files(void); void pal_input_skip_comments(FILE* file, FILE* out_file); PalEvent* pal_input_read_head(FILE* file, FILE* out_file, gchar* filename); PalEvent* pal_input_read_event(FILE* file, FILE* out_file, gchar* filename, PalEvent* event_head, PalEvent* del_event); gboolean pal_input_eof(FILE* file); void pal_input_skip_comments(FILE* file, FILE* out_file); #endif pal-0.4.3/src/remind.c0000644000175000017500000001157411043370327014407 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include #include "main.h" #include "output.h" #include "event.h" #include "rl.h" #include "input.h" #include "edit.h" /* escape ' */ static void pal_remind_escape(gchar *string, FILE* tmp_stream) { while(*string != '\0') { if(*string == '$' || *string == '`' || *string == '"' || *string == '\\') { fputc('\\', tmp_stream); fputc(*string, tmp_stream); } else fputc(*string, tmp_stream); string++; } } static void pal_remind_event(void) { PalEvent* remind_event = NULL; GDate* event_date = NULL; gchar* at_string; gchar tmp_name[] = "/tmp/pal-XXXXXX"; FILE* tmp_stream; int return_val; gchar* email_add; G_CONST_RETURN gchar *charset; at_string = g_malloc(1024*sizeof(gchar)); pal_output_fg(BRIGHT, GREEN, "* * * "); pal_output_attr(BRIGHT, _("Event reminder")); pal_output_fg(BRIGHT, GREEN, " * * *\n"); pal_output_fg(BRIGHT, GREEN, "> "); pal_output_wrap(_("This feature allows you to select one event and have an email sent to you about the event at a date/time that you provide. If the event is recurring, you will only receive one reminder. You MUST have atd, crond and sendmail installed and working for this feature to work."),2,2); g_print("\n"); remind_event = pal_rl_get_event(&event_date, TRUE); g_print("\n"); if(remind_event->start_time != NULL) { snprintf(at_string, 1024, "%02d:%02d %04d-%02d-%02dW", remind_event->start_time->hour, remind_event->start_time->min, g_date_get_year(event_date), g_date_get_month(event_date), g_date_get_day(event_date)); } else { snprintf(at_string, 1024, "%02d:%02d %04d-%02d-%02d", 0,0, g_date_get_year(event_date), g_date_get_month(event_date), g_date_get_day(event_date)); } #if 0 pal_rl_default_text = at_string; rl_pre_input_hook = (rl_hook_func_t*) pal_rl_default_text_fn; at_string = pal_rl_get_line(_("Remind me on (HH:MM YYYY-MM-DD): "), settings->term_rows-2, 0); rl_pre_input_hook = NULL; #endif at_string = pal_rl_get_line_default(_("Remind me on (HH:MM YYYY-MM-DD): "), settings->term_rows-2, 0, at_string); #if 0 pal_rl_default_text = g_strdup(g_get_user_name()); rl_pre_input_hook = (rl_hook_func_t*) pal_rl_default_text_fn; email_add = pal_rl_get_line(_("Username on local machine or email address: "), settings->term_rows-2, 0); rl_pre_input_hook = NULL; #endif email_add = pal_rl_get_line_default(_("Username on local machine or email address: "), settings->term_rows-2, 0, g_strdup(g_get_user_name())); mkstemp(tmp_name); tmp_stream = fopen(tmp_name, "w"); fputs("echo \"", tmp_stream); fputs("From: \"pal\" \n", tmp_stream); fputs("To: ", tmp_stream); fputs(email_add, tmp_stream); fputs("\n", tmp_stream); g_get_charset(&charset); fputs("Content-Type: text/plain; charset=", tmp_stream); fputs(charset, tmp_stream); fputs("\n", tmp_stream); fputs("Subject: [pal] ", tmp_stream); pal_remind_escape(g_strndup(remind_event->text, 128), tmp_stream); fputs("\n\n", tmp_stream); fputs(_("Event: "), tmp_stream); pal_remind_escape(remind_event->text, tmp_stream); fputs("\n", tmp_stream); fputs(_("Event date: "), tmp_stream); { gchar pretty_date[128]; g_date_strftime(pretty_date, 128, settings->date_fmt, event_date); fputs(pretty_date, tmp_stream); } fputs("\n", tmp_stream); fputs(_("Event type: "), tmp_stream); pal_remind_escape(remind_event->type, tmp_stream); fputs("\n", tmp_stream); fputs("\"| /usr/sbin/sendmail ", tmp_stream); fputs(email_add, tmp_stream); fclose(tmp_stream); pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("Attempting to run 'at'...\n")); g_print("at -f %s %s\n", tmp_name, at_string); return_val = system(g_strconcat("at -f ", tmp_name, " ", at_string, NULL)); if(return_val != 0) pal_output_error(_("ERROR: Date string was invalid or could not run 'at'. Is 'atd' running?")); else { pal_output_fg(BRIGHT, GREEN, ">>> "); g_print(_("Successfully added event to the 'at' queue.\n")); } remove(tmp_name); } pal-0.4.3/src/colorize.c0000644000175000017500000001201111043370327014742 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include /* for getenv() */ #include #include "main.h" #include "colorize.h" static int use_colors = -1; /* -2 = no colors, can't turn them on later if this is set; -1 = don't know; 0 = no colors; 1 = colors */ /* Sets use_colors variable depending on the terminal type. This is very crude. */ static void color_term(void) { char *term = getenv("TERM"); use_colors = 0; /* don't use colors by default */ if(term == NULL) return; /* use colors if TERM variable is one of the following */ if( getenv("COLORTERM") != NULL || !g_ascii_strncasecmp(term, "xterm", 5) || !g_ascii_strncasecmp(term, "xterm-color", 11) || !g_ascii_strncasecmp(term, "linux", 5) || /* linux console */ !g_ascii_strncasecmp(term, "ansi", 4) || !g_ascii_strncasecmp(term, "Eterm", 5) || !g_ascii_strncasecmp(term, "dtterm", 6) || /* Solaris */ !g_ascii_strncasecmp(term, "rxvt", 4) || /* rxvt & aterm */ !g_ascii_strncasecmp(term, "cygwin", 6) || !g_ascii_strncasecmp(term, "screen", 6)) use_colors = 1; /* make sure TERM=dumb didn't slip by with COLORTERM set */ if(!g_ascii_strncasecmp(term, "dumb", 4)) use_colors = 0; } /* allows user to manually set use_colors variable */ void set_colorize(const int in) { if(use_colors != -2) use_colors = in; } static int get_curses_color(const int color) { switch(color) { case BLACK: return COLOR_BLACK; break; case RED: return COLOR_RED; break; case GREEN: return COLOR_GREEN; break; case YELLOW: return COLOR_YELLOW; break; case BLUE: return COLOR_BLUE; break; case MAGENTA: return COLOR_MAGENTA; break; case CYAN: return COLOR_CYAN; break; case WHITE: return COLOR_WHITE; break; default: return COLOR_GREEN; } } void colorize_xterm_title(gchar *title) { if(use_colors == -1) color_term(); /* If the terminal doesn't support colors, it probably doesn't * support setting the term title */ if(use_colors == 0 || use_colors == -2) return; printf("\033]0;%s\007", title); } void colorize_fg(const int attribute, const int foreground) { /* determine use_colors variable if it isn't set yet. */ if(use_colors == -1) color_term(); /* don't do anything if not using colors */ if(use_colors == 0 || use_colors == -2) return; /* Command is the control command to the terminal */ if(settings->curses) wattrset(pal_curwin, A_BOLD | COLOR_PAIR(get_curses_color(foreground))); else printf("%c[%d;%dm", 0x1B, attribute, foreground+30); } void colorize_bright(void) { /* determine use_colors variable if it isn't set yet. */ if(use_colors == -1) color_term(); /* don't do anything if not using colors */ if(use_colors == 0 || use_colors == -2) return; /* Command is the control command to the terminal */ if(settings->curses) wattrset(pal_curwin, A_BOLD); else printf("%c[%dm", 0x1B, BRIGHT); } void colorize_error(void) { /* determine use_colors variable if it isn't set yet. */ if(use_colors == -1) color_term(); /* don't do anything if not using colors */ if(use_colors == 0 || use_colors == -2) return; /* Command is the control command to the terminal */ if(settings->curses) wattrset(pal_curwin, A_BOLD | COLOR_PAIR(COLOR_RED)); else g_printerr("%c[%d;%dm", 0x1B, BRIGHT, RED+30); } void colorize_reset(void) { /* determine use_colors variable if it isn't set yet. */ if(use_colors == -1) color_term(); /* don't do anything if not using colors */ if(use_colors == 0 || use_colors == -2) return; if(settings->curses) wattrset(pal_curwin, A_NORMAL); else g_print("%c[0m", 0x1B); } static const char *string_colors[] = { "black", "red", "green", "yellow", "blue", "magenta", "cyan", "white" }; /* free returned string when done. */ gchar* string_color_of(const int color) { if(color >=0 && color < 8) return g_strdup(string_colors[color]); else /* when in doubt, use default color */ return string_color_of(settings->event_color); } /* returns -1 on failure to match */ int int_color_of(gchar* string) { int i; for(i=0; i<8; i++) { if(g_ascii_strcasecmp(string, string_colors[i]) == 0) return i; } return -1; } pal-0.4.3/src/html.c0000644000175000017500000001534711043370327014077 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include "main.h" #include "event.h" #include "html.h" #include "colorize.h" /* prints out the string but properly escapes things for HTML */ static void pal_html_escape_print(gchar* s) { gunichar c; while( (c = g_utf8_get_char(s)) != '\0') { if(c == '<') /* < to < */ g_print("<"); else if(c == '>') /* > to > */ g_print(">"); else if(c == '&') /* & to *amp; */ g_print("&"); else if(c >= 32 && c < 128) /* ASCII */ g_print("%c", c); else g_print("&#%d;", c); /* unicode */ s = g_utf8_next_char(s); } } /* finishes with date on the first day of the next month */ static void pal_html_month(GDate* date, gboolean force_month_label, const GDate* today) { gint orig_month = g_date_get_month(date); int i; gchar buf[1024] = ""; gchar start[64] = ""; gchar end[64] = ""; fputs("\n", stdout); g_date_strftime(buf, 1024, "%B %Y", date); g_print("\n", buf); fputs("\n", stdout); if(!settings->week_start_monday) g_print("%s%s%s\n", start, _("Sunday"), end); g_print("%s%s%s\n", start, _("Monday"), end); g_print("%s%s%s\n", start, _("Tuesday"), end); g_print("%s%s%s\n", start, _("Wednesday"), end); g_print("%s%s%s\n", start, _("Thursday"), end); g_print("%s%s%s\n", start, _("Friday"), end); g_print("%s%s%s\n", start, _("Saturday"), end); if(settings->week_start_monday) g_print("%s%s%s\n", start, _("Sunday"), end); fputs("\n", stdout); /* start the month on the right weekday */ if(settings->week_start_monday) { if(g_date_get_weekday(date) != 1) { fputs("\n", stdout); for(i=0; i \n", stdout); } } } else { if(g_date_get_weekday(date) != 7) { fputs("\n", stdout); for(i=0; i \n", stdout); } } } while(g_date_get_month(date) == orig_month) { GList* events = get_events(date); gint num_events = g_list_length(events); gint num_events_printed = 0; GList* item = NULL; if(( settings->week_start_monday && g_date_get_weekday(date) == 1) || (!settings->week_start_monday && g_date_get_weekday(date) == 7)) fputs("\n", stdout); /* make today bright */ if(g_date_compare(date,today) == 0) g_print("\n"); if((settings->week_start_monday && g_date_get_weekday(date) == 7) || (!settings->week_start_monday && g_date_get_weekday(date) == 6)) fputs("\n", stdout); g_date_add_days(date,1); g_list_free(events); } /* we are on the first day of the next month, go back to the last * day */ g_date_add_days(date, -1); /* skip to end of calendar */ if(settings->week_start_monday) /* set i to the number of blanks to print */ i = 7 - g_date_get_weekday(date); else { if(g_date_get_weekday(date) == 7) i = 6; else i = 6 - g_date_get_weekday(date); } while(i > 0) { fputs("", stdout); i--; } fputs("
%s
%02d
\n", g_date_get_day(date)); else { switch(g_date_get_weekday(date)) { case 1: g_print("
%02d
\n", g_date_get_day(date)); break; case 2: g_print("
%02d
\n", g_date_get_day(date)); break; case 3: g_print("
%02d
\n", g_date_get_day(date)); break; case 4: g_print("
%02d
\n", g_date_get_day(date)); break; case 5: g_print("
%02d
\n", g_date_get_day(date)); break; case 6: g_print("
%02d
\n", g_date_get_day(date)); break; case 7: g_print("
%02d
\n", g_date_get_day(date)); break; default: /* shouldn't happen */ break; } } item = g_list_first(events); /* while there are more events to be displayed */ while(num_events > num_events_printed) { gchar* event_text = pal_event_escape((PalEvent*) (item->data), date); g_print("\n", string_color_of(((PalEvent*) (item->data))->color)); fputs("* ", stdout); pal_html_escape_print(event_text); fputs("
\n", stdout); fputs("
\n", stdout); num_events_printed++; item = g_list_next(item); g_free(event_text); } g_print("
 
\n", stdout); /* jump one day ahead to the first day of the next month */ g_date_add_days(date, 1); } void pal_html_out() { gint on_month = 0; GDate* today = g_date_new(); GDate* date = g_date_new(); if(settings->query_date == NULL) { g_date_set_time_t(today, time(NULL)); g_date_set_time_t(date, time(NULL)); } else { g_date_set_day(today, g_date_get_day(settings->query_date)); g_date_set_month(today, g_date_get_month(settings->query_date)); g_date_set_year(today, g_date_get_year(settings->query_date)); g_date_set_day(date, g_date_get_day(settings->query_date)); g_date_set_month(date, g_date_get_month(settings->query_date)); g_date_set_year(date, g_date_get_year(settings->query_date)); } /* back up to the first of the month */ g_date_subtract_days(date, g_date_get_day(date) - 1); g_print("%s %s %s", "\n"); for(on_month=0; on_month < settings->cal_lines; on_month++) pal_html_month(date, TRUE, today); g_print("

%s

\n", _("Calendar created with pal.")); } pal-0.4.3/src/remind.h0000644000175000017500000000152011043370327014402 0ustar kleptogkleptog#ifndef PAL_REMIND_H #define PAL_REMIND_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ void pal_remind_event(void); #endif pal-0.4.3/src/del.h0000644000175000017500000000156511043370327013701 0ustar kleptogkleptog#ifndef PAL_DEL_H #define PAL_DEL_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ void pal_del_event(void); void pal_del_write_file(PalEvent* dead_event); #endif pal-0.4.3/src/add.c0000644000175000017500000002663011043370327013660 0ustar kleptogkleptog/* pal * * Copyright (C) 2006, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include "main.h" #include "output.h" #include "event.h" #include "rl.h" /* This only works when 'number' is between 1 and 10 inclusive */ void pal_add_suffix(gint number, gchar* suffix, gint buf_size) { number = number % 10; switch(number) { case 1: snprintf(suffix, buf_size, "%s", _("1st")); return; case 2: snprintf(suffix, buf_size, "%s", _("2nd")); return; case 3: snprintf(suffix, buf_size, "%s", _("3rd")); return; case 4: snprintf(suffix, buf_size, "%s", _("4th")); return; case 5: snprintf(suffix, buf_size, "%s", _("5th")); return; case 6: snprintf(suffix, buf_size, "%s", _("6th")); return; case 7: snprintf(suffix, buf_size, "%s", _("7th")); return; case 8: snprintf(suffix, buf_size, "%s", _("8th")); return; case 9: snprintf(suffix, buf_size, "%s", _("9th")); return; case 10: snprintf(suffix, buf_size, "%s", _("10th")); return; default: *suffix = '\0'; return; } } /* convert numerical representation of weekdays: from: 1(mon) -> 7(sun) to: 1(sun) -> 7(sat) */ static inline gint pal_add_weekday_convert(gint weekday) { if(weekday == 7) return 1; return weekday+1; } static gchar* pal_add_get_range( GDate *date ) { pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("Does the event have start and end dates? ")); if(pal_rl_get_y_n(_("[y/n]: "))) { GDate* d1 = NULL; GDate* d2 = NULL; gchar buf[1024] = ""; gchar* s = NULL; gint x,y; g_print("\n"); getyx( stdscr, y, x ); do { /* set back to null for loop to work properly */ d1 = NULL; d2 = NULL; move(y,x); clrtobot(); refresh(); while(d1 == NULL) { s = get_key(date); strcpy( buf, s ); g_free(s); #if 0 pal_rl_default_text = buf; rl_pre_input_hook = (rl_hook_func_t*) pal_rl_default_text_fn; s = pal_rl_get_line(_("Start date: "), y, 0); g_print("\n"); rl_pre_input_hook = NULL; #endif s = pal_rl_get_line_default(_("Start date: "), y, 0, buf); g_print("\n"); d1 = get_query_date(s, TRUE); if( !d1 ) rl_ding(); g_free(s); } clrtobot(); while(d2 == NULL) { s = pal_rl_get_raw_line(_("End date (blank is none): "), y+1, 0); if( *s == 0 ) { g_free(s); s = g_strdup( "30000101" ); } g_print("\n"); d2 = get_query_date(s, TRUE); if( !d2 ) rl_ding(); else { if(g_date_days_between(d1,d2) < 1) { pal_output_error(_("ERROR: End date must be after start date.\n")); clrtobot(); g_date_free(d2); d2 = NULL; } } g_free(s); } g_print("\n"); move(y,0); clrtobot(); g_date_strftime(buf, 1024, "%a %e %b %Y", d1); pal_output_fg(BRIGHT, GREEN, _("Start date: ")); g_print("%s\n", buf); g_date_strftime(buf, 1024, "%a %e %b %Y", d2); pal_output_fg(BRIGHT, GREEN, _("End date: ")); g_print("%s\n", buf); snprintf(buf, 1024, "%s ", _("Accept? [y/n]:")); } while(!pal_rl_get_y_n(buf)); s = g_strconcat(":", get_key(d1), ":", get_key(d2), NULL); g_date_free(d1); g_date_free(d2); return s; } else return g_strdup(""); } /* reuturned string should be freed */ static gchar* pal_add_get_recur(GDate* date) { gchar* selection = NULL; int i; gint x,y; getyx( stdscr, y, x ); pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("Select how often this event occurs\n")); for( i=0; i < PAL_NUM_EVENTTYPES; i++ ) { char buffer[16] = ""; char *descr = NULL; descr = PalEventTypes[i].get_descr(date); if( !descr ) /* Not applicable */ continue; sprintf( buffer, " %2d ", i ); pal_output_attr(BRIGHT, buffer); g_print("- %s\n", descr); g_free(descr); } do { int sel; gchar selkey[MAX_KEYLEN] = ""; gchar *descr = NULL; gint promptx,prompty; getyx( stdscr, prompty, promptx ); selection = pal_rl_get_line(_("Select type: "), prompty, 0); if( sscanf( selection, "%d%*s", &sel ) != 1 ) { rl_ding(); continue; } if( sel < 0 || sel >= PAL_NUM_EVENTTYPES ) { rl_ding(); continue; } if( PalEventTypes[sel].get_key( date, selkey ) != TRUE ) { rl_ding(); continue; } descr = PalEventTypes[sel].get_descr(date); move( y, 0 ); pal_output_fg(BRIGHT, GREEN, _("Event type: ")); g_print("%s\n", descr); clrtobot(); g_free(descr); if( PalEventTypes[sel].period == PAL_ONCEONLY ) return g_strdup(selkey); return g_strconcat(selkey, pal_add_get_range(date), NULL); }while(1); } static gchar* pal_add_get_desc(void) { char* desc = NULL; char* olddesc = NULL; int y,x; pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("What is the description of the event?\n")); getyx( stdscr, y, x ); do{ move(y,x); clrtobot(); olddesc = desc; #if 0 if(desc != NULL) { pal_rl_default_text = desc; rl_pre_input_hook = (rl_hook_func_t*) pal_rl_default_text_fn; } desc = pal_rl_get_line(_("Description: "), y, x); rl_pre_input_hook = NULL; #endif desc = pal_rl_get_line_default(_("Description: "), y, x, olddesc); g_free(olddesc); g_print("\n"); } while(!pal_rl_get_y_n(_("Is this description correct? [y/n]: "))); return desc; } /* prompts for a file name */ static gchar* pal_add_get_file(void) { char* filename = NULL; gboolean prompt_again = FALSE; int y,x; pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("Calendar file (usually ending with \".pal\") to add event to:\n")); getyx( stdscr, y, x ); /* get the filename */ do { rl_completion_entry_function = rl_filename_completion_function; prompt_again = FALSE; filename = pal_rl_get_line_default(_("Filename: "), y, 0, g_strdup("~/.pal/")); /* clear any filename completions */ clrtobot(); /* if first character is ~, replace it with the home directory */ if(*filename == '~') { char* orig_filename = filename; filename = g_strconcat(g_get_home_dir(), filename+1, NULL); g_free(orig_filename); } /* check if file exists */ if(g_file_test(filename, G_FILE_TEST_EXISTS)) { /* make sure it aint a directory */ if(g_file_test(filename, G_FILE_TEST_IS_DIR)) { g_print("\n"); pal_output_error(_("ERROR: %s is a directory.\n"), filename); prompt_again = TRUE; } } else { int y,x; getyx(stdscr, y,x); /* ask to create the file if it doesn't exist */ g_print("\n"); pal_output_error(_("WARNING: %s does not exist.\n"), filename); if(!pal_rl_get_y_n(_("Create? [y/n]: "))) { move(y,x); clrtobot(); prompt_again = TRUE; } else { /* create the file */ FILE* file = fopen(filename, "w"); if(file == NULL) { move(y+1,0); pal_output_error(_("ERROR: Can't create %s.\n"), filename); clrtobot(); prompt_again = TRUE; } else { gchar *markers = NULL; gchar *event_type = NULL; gchar *top_line = NULL; g_print("\n"); pal_output_fg(BRIGHT, GREEN, "> "); g_print(_("Information for %s:\n"), filename); getyx( stdscr, y, x ); do markers = pal_rl_get_line(_("2 character marker for calendar: "), y, 0); while(g_utf8_strlen(markers, -1) != 2 || markers[0] == '#'); g_print("\n"); getyx( stdscr, y, x); event_type = pal_rl_get_line(_("Calendar title: "), y, 0); top_line = g_strconcat(markers, " ", event_type, "\n", NULL); g_print("\n"); pal_output_fg(BRIGHT, RED, "> "); g_print("%s\n", _("If you want events in this new calendar file to appear when you run pal,\n you need to manually update ~/.pal/pal.conf")); g_print("%s\n", _("Press any key to continue.")); getch(); fputs(top_line, file); g_free(top_line); g_free(event_type); g_free(markers); fclose(file); } } } if(prompt_again) g_free(filename); }while (prompt_again); /* no more completion necessary */ rl_completion_entry_function = (rl_compentry_func_t*) pal_rl_no_match; return filename; } void pal_add_write_file(gchar* filename, gchar* key, gchar* desc) { FILE *file = NULL; gchar* write_line = NULL; gboolean no_newline = FALSE; /* check for newline at end of file */ do { file = fopen(filename, "r"); if(file == NULL) { pal_output_error(_("ERROR: Can't read from file %s.\n"), filename); if(!pal_rl_get_y_n(_("Try again? [y/n]: "))) return; } } while(file == NULL); fseek(file, -1, SEEK_END); if(fgetc(file)!= '\n') no_newline = TRUE; fclose(file); /* write the new event out to that file */ do { file = fopen(filename, "a"); if(file == NULL) { pal_output_error(_("ERROR: Can't write to file %s.\n"), filename); if(!pal_rl_get_y_n(_("Try again? [y/n]: "))) return; } } while(file == NULL); /* put a newline at end of file if one isn't there already */ if(no_newline) fputc('\n', file); write_line = g_strconcat(key, " ", desc, "\n", NULL); fputs(write_line, file); g_print("\n"); pal_output_fg(BRIGHT, GREEN, ">>> "); g_print(_("Wrote new event \"%s %s\" to %s.\n"), key, desc, filename); refresh(); { int c; do c = getch(); while(c == ERR); } g_free(write_line); fclose(file); } void pal_add_event( GDate *selected_date ) { gchar* filename = NULL; gchar* description = NULL; gchar* key = NULL; PalEvent *event = NULL; char buf[128] =""; clear(); pal_output_fg(BRIGHT, GREEN, "* * * "); pal_output_attr(BRIGHT, _("Add an event")); pal_output_fg(BRIGHT, GREEN, " * * *\n"); pal_output_fg(BRIGHT, GREEN, _("Selected date: ")); g_date_strftime( buf, 128, settings->date_fmt, selected_date ); pal_output_attr(BRIGHT, buf); pal_output_fg(BRIGHT, GREEN, "\n"); filename = pal_add_get_file(); g_print("\n"); key = pal_add_get_recur(selected_date); g_print("\n"); pal_output_fg(BRIGHT, GREEN, _("Date (in pal's format):")); g_print(" %s\n\n", key); description = pal_add_get_desc(); /* Check the event is parsable */ event = pal_event_init(); if(!parse_event(event, key)) { pal_output_error("INTERNAL ERROR: Please report this error message along with\n"); pal_output_error(" the input that generated it.\n"); pal_output_error("INVALID KEY: %s\n", key); getch(); } else pal_add_write_file(filename, key, description); pal_event_free(event); g_free(filename); g_free(description); g_free(key); pal_main_reload(); } pal-0.4.3/src/edit.h0000644000175000017500000000163211043370327014055 0ustar kleptogkleptog#ifndef PAL_EDIT_H #define PAL_EDIT_H /* pal * * Copyright (C) 2004--2006, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include "main.h" gchar* pal_edit_desc(gchar* text); void pal_edit_event(PalEvent* event, GDate *d); #endif pal-0.4.3/src/Makefile.defs0000644000175000017500000000114211043370327015333 0ustar kleptogkleptog# This file contains variables that are the same for both pal and # gpal. # directory to install to. Depending on your distribution, you might # want to change this to /usr/local prefix = /usr CC = gcc PAL_VERSION = 0.4.3 # used for portage, rpm, ... DESTDIR = # optimizations/warnings OPT = -O2 -Wall ifeq ($(DEBUG),1) OPT = -g -Wall -pedantic -Wstrict-prototypes endif # defines DEFS = -DPAL_VERSION=\"$(PAL_VERSION)\" -DPREFIX=\"$(prefix)\" ifeq ($(DEBUG),1) DEFS += -DG_DISABLE_DEPRECATED -DDEBUG endif CFLAGS = ${OPT} CPPFLAGS = ${INCLDIR} ${DEFS} LDFLAGS = ${LIBDIR} ${LIBS} pal-0.4.3/src/output.c0000644000175000017500000003471511043370327014473 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include #include #include /* for vsnprintf */ #include #include "main.h" #include "colorize.h" #include "event.h" /* Interface between g_print and ncurses. This is also the print * handler that gets used if we aren't using curses. The default * handler apparently calls fflush() all of the time. This slows down * some of our code that calls fflush() often (such as the code we use * to print out the calendar). */ void pal_output_handler( const gchar *instr ) { gsize strsize; char *outstr = g_locale_from_utf8(instr, -1, NULL, &strsize, NULL); /* if the previous fails, try the filename conversion, it gives reasonable results in most cases */ if(!outstr) outstr = g_filename_from_utf8(instr, -1, NULL, &strsize, NULL); /* If that doesn't work, just use the input string */ if(!outstr) outstr = g_strdup(instr); if(settings->curses) waddnstr(pal_curwin, outstr, strsize); else fputs(outstr, stdout); g_free(outstr); } /* set attribute w/o changing color */ void pal_output_attr(gint attr, gchar *formatString, ...) { gchar buf[2048] = ""; va_list argptr; va_start(argptr, formatString); if( attr == BRIGHT ) colorize_bright(); /* glib 2.2 provides g_vfprintf */ vsnprintf(buf, 2048, formatString, argptr); g_print("%s", buf); colorize_reset(); va_end(argptr); } /* set foreground color and attribute */ void pal_output_fg( gint attr, gint color, gchar *formatString, ...) { gchar buf[2048] = ""; va_list argptr; va_start(argptr, formatString); colorize_fg(attr, color); /* glib 2.2 provides g_vfprintf */ vsnprintf(buf, 2048, formatString, argptr); g_print("%s", buf); colorize_reset(); va_end(argptr); } void pal_output_error(char *formatString, ... ) { gchar buf[2048] = ""; va_list argptr; va_start( argptr, formatString ); colorize_error(); /* glib 2.2 provides g_vfprintf */ vsnprintf(buf, 2048, formatString, argptr); g_printerr("%s", buf); /* use g_print to convert from UTF-8 */ colorize_reset(); va_end(argptr); } /* finishes with date on the sunday of the next week */ static void pal_output_text_week(GDate* date, gboolean force_month_label, const GDate* today) { gint i=0; if(settings->week_start_monday) /* go to last day in week (sun) */ while(g_date_get_weekday(date) != 7) g_date_add_days(date,1); else /* go to last day in week (sat) */ while(g_date_get_weekday(date) != 6) g_date_add_days(date,1); for(i=0; i<7; i++) { if(g_date_get_day(date) == 1) force_month_label = TRUE; g_date_subtract_days(date,1); } g_date_add_days(date,1); /* date is now at beginning of week */ if(force_month_label) { gchar buf[1024]; g_date_add_days(date,6); g_date_strftime(buf, 128, "%b", date); g_date_subtract_days(date,6); /* make sure we're only showing 3 characters */ if(g_utf8_strlen(buf, -1) != 3) { /* append whitespace in case "buf" is too short */ gchar* s = g_strconcat(buf, " ", NULL); /* just show first 3 characters of month */ g_utf8_strncpy(buf, s, 3); g_free(s); } pal_output_fg(BRIGHT, GREEN, "%s ", buf); } else if( settings->show_weeknum ) { gint weeknum = settings->week_start_monday ? g_date_get_monday_week_of_year(date) : g_date_get_sunday_week_of_year(date); pal_output_fg(BRIGHT, GREEN, " %2d ", weeknum); } else g_print(" "); for(i=0; i<7; i++) { GList* events = NULL; gunichar start=' ', end=' '; gchar utf8_buf[8]; gint color = settings->event_color; events = get_events(date); if(g_date_compare(date,today) == 0) start = end = '@'; else if(events != NULL) { GList* item = g_list_first(events); PalEvent *event = (PalEvent*) item->data; gboolean same_char = TRUE; gboolean same_color = TRUE; /* skip to a event that isn't hidden or to the end of the list */ while(g_list_length(item) > 1 && event->hide) { item = g_list_next(item); event = (PalEvent*) item->data; } /* save the markers for the event */ if(event->hide) start = ' ', end = ' '; else { start = event->start; end = event->end; color = event->color; } /* if multiple events left */ while(g_list_length(item) > 1) { item = g_list_next(item); event = (PalEvent*) item->data; /* find next non-hidden event */ while(g_list_length(item) > 1 && event->hide) { item = g_list_next(item); event = (PalEvent*) item->data; } /* if this event is hidden, there aren't any more non-hidden events left */ /* if this event isn't hidden, then determine if it has different markers */ if( ! event->hide ) { gunichar new_start = event->start; gunichar new_end = event->end; gint new_color = event->color; if(new_start != start || new_end != end) same_char = FALSE; if(new_color != color) same_color = FALSE; } if(same_char == FALSE) start = '*', end = '*'; if(same_color == FALSE) color = -1; } } utf8_buf[g_unichar_to_utf8(start, utf8_buf)] = '\0'; /* print color for marker if needed */ if(start != ' ' && end != ' ') { if(color == -1) pal_output_fg(BRIGHT, settings->event_color, utf8_buf); else pal_output_fg(BRIGHT, color, utf8_buf); } else g_print(utf8_buf); if(g_date_compare(date,today) == 0) /* make today bright */ pal_output_attr(BRIGHT, "%02d", g_date_get_day(date)); else g_print("%02d", g_date_get_day(date)); utf8_buf[g_unichar_to_utf8(end, utf8_buf)] = '\0'; /* print color for marker if needed */ if(start != ' ' && end != ' ') { if(color == -1) pal_output_fg(BRIGHT, settings->event_color, utf8_buf); else pal_output_fg(BRIGHT, color, utf8_buf); } else g_print(utf8_buf); /* print extra space between days */ if(i != 6) g_print(" "); g_date_add_days(date,1); g_list_free(events); } } static void pal_output_week(GDate* date, gboolean force_month_label, const GDate* today) { pal_output_text_week(date, force_month_label, today); if(!settings->no_columns && settings->term_cols >= 77) { pal_output_fg(DIM,YELLOW,"%s","|"); /* skip ahead to next column */ g_date_subtract_days(date, 6); g_date_add_days(date, settings->cal_lines*7); pal_output_text_week(date, force_month_label, today); /* skip back to where we were */ g_date_subtract_days(date, settings->cal_lines*7); } if(settings->term_cols != 77) g_print("\n"); } void pal_output_cal(gint num_lines, const GDate* today) { gint on_week = 0; gchar* week_hdr = NULL; GDate* date = NULL; if(num_lines <= 0) return; date = g_date_new(); memcpy(date, today, sizeof(GDate)); if(settings->week_start_monday) week_hdr = g_strdup(_("Mo Tu We Th Fr Sa Su")); else week_hdr = g_strdup(_("Su Mo Tu We Th Fr Sa")); /* if showing enough lines, show previous week. */ if(num_lines > 3) g_date_subtract_days(date, 7); if(settings->no_columns || settings->term_cols < 77) pal_output_fg(BRIGHT,GREEN, " %s\n", week_hdr); else { pal_output_fg(BRIGHT,GREEN," %s ", week_hdr); pal_output_fg(DIM,YELLOW,"%s","|"); pal_output_fg(BRIGHT,GREEN," %s\n", week_hdr); } g_free(week_hdr); while(on_week < num_lines) { if(on_week == 0) pal_output_week(date, TRUE, today); else pal_output_week(date, FALSE, today); on_week++; } g_date_free( date ); } /* replaces tabs with spaces */ static void pal_output_strip_tabs(gchar* string) { gchar *ptr = string; while(*ptr != '\0') { if(*ptr == '\t') *ptr = ' '; ptr++; } } /* returns the length of the next word */ static gint pal_output_wordlen(gchar* string) { gchar* p = string; int i=0; while(*p != ' ' && *p != '\0') { p = g_utf8_next_char(p); i++; } return i; } /* This function does not yet handle tabs and color codes. Tabs * should be stripped from 'string' before this is called. * "chars_used" indicates the number of characters already used on the * line that "string" will be printed out on. * Returns the number of lines printed. */ int pal_output_wrap(gchar* string, gint chars_used, gint indent) { gint numlines = 0; gchar* s = string; gint width = settings->term_cols - 1; /* -1 to avoid unexpected wrap */ if( width <= 0 ) width = 10000; while(*s != '\0') { /* print out any leading whitespace on this line */ while(*s == ' ' && chars_used < width) { g_print(" "); chars_used++; s = g_utf8_next_char(s); } /* if word doesn't fit on line, split it */ if(pal_output_wordlen(s)+chars_used > width) { gchar line[2048]; g_utf8_strncpy(line, s, width - chars_used); g_print("%s\n", line); /* print as much as we can */ numlines++; s = g_utf8_offset_to_pointer(s, width - chars_used); chars_used = 0; } else /* if next word fits on line */ { while(*s != '\0' && pal_output_wordlen(s)+chars_used <= width) { /* if the next word is not a blank, copy the word */ if(*s != ' ') { gint word_len = pal_output_wordlen(s); gchar word[2048]; g_utf8_strncpy(word, s, word_len); g_print("%s", word); s = g_utf8_offset_to_pointer(s, word_len); chars_used += word_len; } /* print out any spaces that follow the word */ while(*s == ' ' && chars_used < width) { g_print(" "); chars_used++; s = g_utf8_next_char(s); } /* if we filled line up perfectly, and there is a * space next in the string, ignore it---the newline * will act as the space */ if(chars_used == width && *s == ' ') { s = g_utf8_next_char(s); /* if the next line is a space too, break out of * this loop. If we don't break, whitespace might * not be preserved properly. */ if(*s == ' ') break; } } numlines++; g_print("\n"); chars_used = width; } /* if not done, print indents for next line */ if(*s != '\0') { gint i; /* now, chars_used == width, onto the next line! */ chars_used = indent; for(i=0; i"); else if(event->color == -1) pal_output_fg(BRIGHT, settings->event_color, "%s ", "*"); else pal_output_fg(BRIGHT, event->color, "%s ", "*"); pal_output_strip_tabs(event->text); pal_output_strip_tabs(event->type); event_text = pal_event_escape(event, date); if(settings->compact_list) { gchar* s = NULL; g_date_strftime(date_text, 128, settings->compact_date_fmt, date); pal_output_attr(BRIGHT, "%s ", date_text); if(settings->hide_event_type) s = g_strconcat(event_text, NULL); else s = g_strconcat(event->type, ": ", event_text, NULL); numlines += pal_output_wrap(s, indent+g_utf8_strlen(date_text,-1)+1, indent); g_free(s); } else { if(settings->hide_event_type) numlines += pal_output_wrap(event_text, indent, indent); else { gchar* s = g_strconcat(event->type, ": ", event_text, NULL); numlines += pal_output_wrap(s, indent, indent); g_free(s); } } g_free(event_text); return numlines; } void pal_output_date_line(const GDate* date) { gchar pretty_date[128]; gint diff = 0; GDate* today = g_date_new(); g_date_set_time_t(today, time(NULL)); g_date_strftime(pretty_date, 128, settings->date_fmt, date); pal_output_attr(BRIGHT, "%s", pretty_date); g_print(" - "); diff = g_date_days_between(today, date); if(diff == 0) pal_output_fg(BRIGHT, RED, "%s", _("Today")); else if(diff == 1) pal_output_fg(BRIGHT, YELLOW, "%s", _("Tomorrow")); else if(diff == -1) g_print("%s", _("Yesterday")); else if(diff > 1) g_print(_("%d days away"), diff); else if(diff < -1) g_print(_("%d days ago"), -1*diff); g_print("\n"); g_date_free(today); } /* outputs the events in the order of PalEvent->file_num. Returns the number of lines printed. */ int pal_output_date(GDate* date, gboolean show_empty_days, int selected_event) { gint numlines = 0; GList* events = get_events(date); gint num_events = g_list_length(events); if(events != NULL || show_empty_days) { GList* item = NULL; int i; if(!settings->compact_list) { pal_output_date_line(date); numlines++; } item = g_list_first(events); for(i=0; idata), date, i==selected_event); item = g_list_next(item); } if(num_events == 0) { if(settings->compact_list) { gchar pretty_date[128]; g_date_strftime(pretty_date, 128, settings->compact_date_fmt, date); pal_output_attr(BRIGHT, " %s ", pretty_date); g_print("%s\n", _("No events.")); numlines++; } else { g_print("%s\n", _("No events.")); numlines++; } } if(!settings->compact_list) { g_print("\n"); numlines++; } } return numlines; } /* returns the PalEvent for the given event_number */ PalEvent* pal_output_event_num(const GDate* date, gint event_number) { GList* events = get_events(date); gint num_events = g_list_length(events); if(events == NULL || event_number < 1 || event_number > num_events) return NULL; return (PalEvent*) g_list_nth_data(events, event_number-1); } pal-0.4.3/src/event.h0000644000175000017500000000262311043370327014252 0ustar kleptogkleptog#ifndef PAL_EVENT_H #define PAL_EVENT_H /* pal * * Copyright (C) 2003, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ /* returns a list of events on the givent date */ GList* get_events(const GDate* date); /* Return just the count */ gint pal_get_event_count( GDate *date ); PalEvent* pal_event_init(void); void pal_event_free(PalEvent* event); void pal_event_fill_dates(PalEvent* pal_event, const gchar* date_string); gboolean parse_event(PalEvent *event, const gchar* date_string); gchar* get_key(const GDate* date); GDate* get_date(const gchar* key); gchar* pal_event_date_string_to_key(const gchar* date_string); PalEvent* pal_event_copy(PalEvent* orig); gchar* pal_event_escape(const PalEvent* event, const GDate* today); #endif pal-0.4.3/src/manage.c0000644000175000017500000004405011043370327014354 0ustar kleptogkleptog/* pal * * Copyright (C) 2004--2006, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include "main.h" #include #include #include #include #include /* get # columns for terminal */ #include #include #include "output.h" #include "event.h" #include "colorize.h" #include "edit.h" #include "add.h" #include "del.h" #include "rl.h" #include "search.h" static int selected_event = -1; static int events_on_day = 0; static GDate* selected_day = NULL; static GDate* today = NULL; /* Currently active window for g_print to output to */ WINDOW *pal_curwin = NULL; /* Redisplays the main calendar + event list screen. This function * does not clear the first two lines of the screen before * drawing---so it will not clear any prompts if they exist. * * If you wish to clear the entire screen before drawing, call * pal_manage_refresh_at() first. */ static void pal_manage_refresh_at(void) { gchar date_text[128]; gint linecount = 0; GDate *date = g_date_new(); gint saved_cols; gboolean finished_printing = FALSE; /* Don't touch the first two lines---they are reserved for * prompts! */ move(2,0); pal_output_cal(settings->cal_lines, selected_day); g_print("\n"); memcpy( date, selected_day, sizeof(GDate) ); /* If we are viewing a event, screen is split in two to display * details. Set this so pal_output_wrap works properly */ saved_cols = settings->term_cols; if( selected_event >= 0 ) settings->term_cols /= 2; /* Note: Because the output of g_print is redirected through * ncurses, we don't have to worry about unexpected scrolling */ while(!finished_printing) { gint thisdaycount = 0; bool isselectedday = (g_date_compare ( date, selected_day ) == 0); thisdaycount = pal_get_event_count(date); if(linecount > 6) settings->term_cols = saved_cols; if( isselectedday ) { events_on_day = thisdaycount; if(selected_event >= events_on_day) selected_event = events_on_day - 1; } if( thisdaycount > 0 || isselectedday ) { gint x,y; getyx( stdscr, y, x ); linecount += pal_output_date(date, TRUE, isselectedday ? selected_event : -1 ); /* if the last thing we printed fell off the screen, erase it */ if(linecount + settings->cal_lines+3 > settings->term_rows-1) { move(y,x); clrtobot(); finished_printing = TRUE; /* break out of loop */ } } g_date_add_days( date, 1 ); if( g_date_days_between(selected_day, date) > INTERACT_DAY_RANGE ) { clrtobot(); finished_printing = TRUE; } } g_date_free(date); /* Draw the event information box if an event is selected */ if( selected_event >= 0 && events_on_day > 0 ) { GList *events = get_events(selected_day); char *ptr = NULL; PalEvent *curevent = NULL; /* If we are viewing a event, screen is split in two to display * details. Set this so pal_output_wrap works properly */ if( selected_event >= 0 ) settings->term_cols /= 2; pal_curwin = subwin(stdscr, 5, saved_cols/2, settings->cal_lines + 4, saved_cols/2); curevent = g_list_nth_data(events, (selected_event >= 0) ? selected_event : 0 ); g_list_free(events); wmove(pal_curwin, 0, 0); pal_output_fg(BRIGHT, GREEN, _("Event Type: ") ); ptr = curevent->eventtype->get_descr( selected_day ); pal_output_wrap( ptr, 12, 5 ); g_free(ptr); pal_output_fg(BRIGHT, GREEN, _("Skip count: ") ); g_print( "%d\n", curevent->period_count ); pal_output_fg(BRIGHT, GREEN, _("Start date: ") ); if( curevent->start_date ) g_date_strftime(date_text, 128, settings->date_fmt, curevent->start_date); else sprintf( date_text, "None" ); g_print( "%s\n", date_text ); pal_output_fg(BRIGHT, GREEN, _("End date: ") ); if( curevent->end_date ) g_date_strftime(date_text, 128, settings->date_fmt, curevent->end_date); else sprintf( date_text, "None" ); g_print( "%s\n", date_text ); pal_output_fg(BRIGHT, GREEN, _("Key: ") ); g_print( "%s\n", curevent->key ); delwin( pal_curwin ); pal_curwin = stdscr; } settings->term_cols = saved_cols; refresh(); } /* pal_manage_refresh clears the entire screen and redraws the * calendar and list of events. */ static void pal_manage_refresh(void) { /* clear the first two prompt lines */ move(0,0); g_print("\n\n"); pal_manage_refresh_at(); } static void pal_manage_finish(int sig) { gchar hostname[128]; endwin(); /* Clear the terminal (code from ncurses /usr/bin/clear program). * If we don't do this sometimes the terminal we return to gets * screwed up. This usually occurs when the terminal was made * larger while pal was running. This isn't our fault---the same * thing happens on other apps like "emacs -nw" too. */ setupterm((char *) 0, STDOUT_FILENO, (int *) 0); tputs(clear_screen, lines > 0 ? lines : 1, putchar); /* set the xterm title to something reasonable */ if(gethostname(hostname, 128) == 0) colorize_xterm_title(hostname); exit(0); } /* Normally, ncurses has a window resize handler that causes getch() to return KEY_RESIZE. However, using readline+ncurses somehow screws it up. So, we implement here what ncurses does by default. */ static void pal_manage_resize(int sig) { #ifndef __CYGWIN__ /* figure out the terminal width if possible */ { struct winsize wsz; if(ioctl(0, TIOCGWINSZ, &wsz) != -1) { settings->term_cols = wsz.ws_col; settings->term_rows = wsz.ws_row; } } #endif /* Tell curses that the screen size has been resized */ if(is_term_resized(settings->term_rows, settings->term_cols)) { resizeterm(settings->term_rows, settings->term_cols); } /* Let the key handler deal with redrawing the screen. This means * that if we are waiting for input from readline, we won't * refresh the screen until after readline is finished. */ ungetch(KEY_RESIZE); return; } static gboolean isearch_direction; /* Refresh function for the isearch */ static void pal_manage_isearch_refresh(void) { GDate *searchdate = g_date_new(); int searchselect = selected_event; gchar buffer[128] = ""; memcpy( searchdate, selected_day, sizeof(GDate) ); move(0,0); clrtoeol(); g_date_strftime(buffer, 128, settings->date_fmt, selected_day); pal_output_fg(BRIGHT, GREEN, _("%s Isearch starting from %s"), isearch_direction ? _("Forward") : _("Backward"), buffer); g_print(" "); /* Only search if there is text to search for */ if( *rl_line_buffer && !pal_search_isearch_event( &searchdate, &searchselect, rl_line_buffer, isearch_direction ) ) { pal_output_fg(BRIGHT, RED, _("No matches found!")); rl_ding(); } else { g_date_free(selected_day); selected_day = searchdate; selected_event = searchselect; pal_manage_refresh_at(); } pal_rl_ncurses_hack(); /* Update cursor */ } /* Does a basic interactive search in the given direction. This is different * from the full search handled in search.c */ static void pal_manage_isearch(gboolean forward) { gchar *searchstring = NULL; GDate *searchdate = g_date_new(); int searchselect = selected_event; memcpy( searchdate, selected_day, sizeof(GDate) ); isearch_direction = forward; /* Clear the first two lines */ move(0, 0); clrtoeol(); move(1, 0); clrtoeol(); /* Temporarily set the refresh function to update while typing */ rl_redisplay_function = pal_manage_isearch_refresh; searchstring = pal_rl_get_raw_line(_("Isearch: "), 1, 0); rl_redisplay_function = pal_rl_ncurses_hack; /* If the user typed something and we can find event, set selected event */ if( *searchstring ) { if( pal_search_isearch_event( &searchdate, &searchselect, rl_line_buffer, isearch_direction ) ) { memcpy( selected_day, searchdate, sizeof(GDate) ); selected_event = searchselect; } } pal_manage_refresh(); g_date_free(searchdate); } /* Scans for the next event in the given direction */ static void pal_manage_scan_for_event( GDate **date, int *eventnum, int dir ) { /* Note, the way this code is written handles the case where eventnum is * -1. In that case it places on the first event following this date */ if( dir > 0 ) { int thisdaycount; int count = 0; (*eventnum)++; if( *eventnum < events_on_day ) return; *eventnum = 0; while( count < 60 ) /* No more than two months */ { g_date_add_days(*date, 1); thisdaycount = pal_get_event_count(*date); if( thisdaycount > 0 ) return; count++; } rl_ding(); return; } else { int thisdaycount; int count = 0; (*eventnum)--; if( *eventnum >= 0 ) return; while( count < 60 ) /* No more than two months */ { g_date_add_days(*date, -1); thisdaycount = pal_get_event_count(*date); if( thisdaycount > 0 ) { *eventnum = thisdaycount - 1; return; } count++; } rl_ding(); return; } } void pal_manage(void) { selected_day = g_date_new(); g_date_set_time_t(selected_day, time(NULL)); today = g_date_new(); g_date_set_time_t(today, time(NULL)); colorize_xterm_title(_("pal calendar")); /* set up readline */ rl_initialize(); /* Initialise readline so we can fiddle stuff */ rl_already_prompted = 1; rl_redisplay_function = pal_rl_ncurses_hack; rl_pre_input_hook = (Function*) pal_rl_ncurses_hack; /* initialize curses */ (void) signal(SIGINT, pal_manage_finish); /* arrange interrupts to terminate */ (void) initscr(); /* initialize the curses library */ keypad(stdscr, TRUE); /* enable keyboard mapping */ (void) nonl(); /* tell curses not to do NL->CR/NL on output */ (void) cbreak(); /* take input chars one at a time, no wait for \n */ (void) halfdelay(1); /* always return from getch() within a tenth of a second */ (void) noecho(); /* echo input - in color */ signal(SIGINT, pal_manage_finish); /* setup function to call on Ctrl+C */ signal(SIGWINCH, pal_manage_resize); /* setup function to call on term resize */ /* adjust some settings if necessary */ getmaxyx(stdscr,settings->term_rows,settings->term_cols); settings->cal_lines = 5; settings->curses = TRUE; pal_curwin = stdscr; if(has_colors()) { start_color(); init_pair(COLOR_BLACK, COLOR_BLACK, COLOR_BLACK); init_pair(COLOR_GREEN, COLOR_GREEN, COLOR_BLACK); init_pair(COLOR_RED, COLOR_RED, COLOR_BLACK); init_pair(COLOR_CYAN, COLOR_CYAN, COLOR_BLACK); init_pair(COLOR_WHITE, COLOR_WHITE, COLOR_BLACK); init_pair(COLOR_MAGENTA, COLOR_MAGENTA, COLOR_BLACK); init_pair(COLOR_BLUE, COLOR_BLUE, COLOR_BLACK); init_pair(COLOR_YELLOW, COLOR_YELLOW, COLOR_BLACK); } else set_colorize(-2); pal_manage_refresh(); move(0, 0); pal_output_fg(BRIGHT, GREEN, "pal %s", PAL_VERSION); g_print(" - "); g_print(_("Press 'h' for help, 'q' to quit.")); for(;;) { int c; while((c = getch()) == ERR); switch(c) { case KEY_RESIZE: pal_manage_refresh(); break; case 'q': case 'Q': pal_manage_finish(0); return; case KEY_LEFT: g_date_add_days(selected_day, -1); pal_manage_refresh(); break; case KEY_RIGHT: case ' ': g_date_add_days(selected_day, 1); pal_manage_refresh(); break; case KEY_UP: if(selected_event == -1) g_date_add_days(selected_day, -7); else pal_manage_scan_for_event( &selected_day, &selected_event, -1 ); pal_manage_refresh(); break; case KEY_DOWN: if(selected_event == -1) g_date_add_days(selected_day, 7); else pal_manage_scan_for_event( &selected_day, &selected_event, 1 ); pal_manage_refresh(); break; case '\t': case '\r': case KEY_ENTER: if(selected_event != -1) selected_event = -1; else if(events_on_day != 0) selected_event = 0; else /* If no event on current day, scan till we find one */ pal_manage_scan_for_event( &selected_day, &selected_event, 1 ); pal_manage_refresh(); break; case 't': /* today */ case 'T': g_date_set_time_t(selected_day, time(NULL)); pal_manage_refresh(); break; case 'g': /* goto date */ case 'G': { gchar* str = pal_rl_get_raw_line(_("Goto date: "), 0, 0); if(strlen(str) > 0) { GDate* new_date = get_query_date(str, FALSE); if(new_date == NULL) { move(0, 0); clrtoeol(); colorize_fg(BRIGHT, RED); g_print("%s is an invalid date!", str); colorize_reset(); } else { g_date_free(selected_day); selected_day = new_date; pal_manage_refresh(); } } else { move(0,0); clrtoeol(); } break; } case 'e': /* edit description */ case 'E': /* Shortcut for days with one event */ if(selected_event == -1 && events_on_day == 1 ) selected_event = 0; if(selected_event != -1) { PalEvent* e = pal_output_event_num(selected_day, selected_event+1); if(e != NULL) { if(e->global) { move(0, 0); clrtoeol(); pal_output_fg(BRIGHT, RED, _("Can't edit global event!")); } else { /* gchar* new_text = pal_edit_desc(e->text); */ gchar* new_text = pal_rl_get_line_default(_("New description: "), 0, 0, e->text); pal_del_write_file(e); pal_add_write_file(e->file_name, e->date_string, new_text); /* need to check for error here! */ g_free(new_text); pal_main_reload(); pal_manage_refresh(); } } } else { move(0,0); clrtoeol(); pal_output_fg(BRIGHT, RED, _("No event selected.")); } break; case 'v': case 'V': if(selected_event != -1) { pal_edit_event(pal_output_event_num(selected_day, selected_event+1), selected_day); pal_manage_refresh(); } break; case 'd': /* edit event date */ case 'D': break; case 'a': /* add event */ case 'A': pal_add_event( selected_day ); pal_manage_refresh(); break; case KEY_DC: /* delete key - kill event */ if(selected_event != -1) { PalEvent* e = pal_output_event_num(selected_day, selected_event+1); if(e != NULL) { move(0, 0); if(e->global) pal_output_fg(BRIGHT, RED, _("Can't delete global event!")); else { if(pal_rl_get_y_n(_("Are you sure you want to delete this event? [y/n]: "))) { selected_event = -1; pal_del_write_file(e); } pal_main_reload(); pal_manage_refresh(); } } } break; case 'r': /* reminder */ case 'R': break; case 's': /* search */ case 'S': break; case '/': /* forward i-search */ pal_manage_isearch( TRUE ); break; case '?': /* backward i-search */ pal_manage_isearch( FALSE ); break; case 'h': /* help */ case 'H': clear(); move(0,0); pal_output_fg(BRIGHT, GREEN, "pal %s\n\n", PAL_VERSION); pal_output_fg(BRIGHT, GREEN, _("LeftArrow")); g_print(" - %s\n", _("Back one day")); pal_output_fg(BRIGHT, GREEN, _("RightArrow")); g_print(" - %s\n", _("Forward one day")); pal_output_fg(BRIGHT, GREEN, _("UpArrow")); g_print(" - %s\n", _("Back one week or event (if in event selection mode)")); pal_output_fg(BRIGHT, GREEN, _("DownArrow")); g_print(" - %s\n", _("Forward one week or event (if in event selection mode)")); pal_output_fg(BRIGHT, GREEN, "h"); g_print(" - %s\n", _("This help screen.")); pal_output_fg(BRIGHT, GREEN, "q"); g_print(" - %s\n", _("Quit")); pal_output_fg(BRIGHT, GREEN, _("Tab, Enter")); g_print(" - %s\n", _("Toggle event selection")); pal_output_fg(BRIGHT, GREEN, "g"); g_print(" - %s\n", _("Jump to a specific date.")); pal_output_fg(BRIGHT, GREEN, "t"); g_print(" - %s\n", _("Jump to today.")); pal_output_fg(BRIGHT, GREEN, "e"); g_print(" - %s\n", _("Edit description of the selected event.")); pal_output_fg(BRIGHT, GREEN, "a"); g_print(" - %s\n", _("Add an event to the selected date.")); pal_output_fg(BRIGHT, GREEN, "/, ?"); g_print(" - %s\n", _("Forward/reverse i-search")); pal_output_fg(BRIGHT, GREEN, _("Delete")); g_print(" - %s\n", _("Delete selected event.")); g_print("\n"); pal_output_fg(BRIGHT, RED, "UNIMPLEMENTED:\n"); g_print("d - %s\n", _("Edit date for selected event.")); g_print("s - %s\n", _("Search for event.")); g_print("r - %s\n", _("Remind me about an event.")); g_print("\n"); g_print(_("Press any key to exit help.")); g_print("\n"); { int c; do c = getch(); while(c == ERR || c == KEY_RESIZE); } pal_manage_refresh(); break; } } } pal-0.4.3/src/event.c0000644000175000017500000005776511043370327014266 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include #include "main.h" #include "event.h" static gint get_nth_day(const GDate* date); static gboolean last_weekday_of_month(const GDate* date); /* Currently in add.c, should be moved at some stage */ void pal_add_suffix(gint number, gchar* suffix, gint buf_size); PalEvent* pal_event_init() { PalEvent* event = g_malloc(sizeof(PalEvent)); event->text = NULL; event->type = NULL; event->start_date = NULL; event->end_date = NULL; event->date_string = NULL; event->start_time = NULL; event->end_time = NULL; event->file_name = NULL; event->key = NULL; event->eventtype = NULL; event->period_count = 1; return event; } PalEvent* pal_event_copy(PalEvent* orig) { PalEvent* new = g_malloc(sizeof(PalEvent)); new->text = g_strdup(orig->text); new->start = orig->start; new->end = orig->end; new->hide = orig->hide; new->type = g_strdup(orig->type); new->file_num = orig->file_num; new->file_name = g_strdup(orig->file_name); new->color = orig->color; if(orig->start_date == NULL) new->start_date = NULL; else { new->start_date = g_malloc(sizeof(GDate)); memcpy(new->start_date, orig->start_date, sizeof(GDate)); } if(orig->end_date == NULL) new->end_date = NULL; else { new->end_date = g_malloc(sizeof(GDate)); memcpy(new->end_date, orig->end_date, sizeof(GDate)); } if(orig->start_time == NULL) new->start_time = NULL; else { new->start_time = g_malloc(sizeof(PalTime)); memcpy(new->start_time, orig->start_time, sizeof(PalTime)); } if(orig->end_time == NULL) new->end_time = NULL; else { new->end_time = g_malloc(sizeof(PalTime)); memcpy(new->end_time, orig->end_time, sizeof(PalTime)); } new->date_string = g_strdup(orig->date_string); new->key = g_strdup(orig->key); new->eventtype = orig->eventtype; new->period_count = orig->period_count; new->global = orig->global; return new; } void pal_event_free(PalEvent* event) { if(event == NULL) return; if(event->text != NULL) g_free(event->text); if(event->type != NULL) g_free(event->type); if(event->start_date != NULL) g_date_free(event->start_date); if(event->end_date != NULL) g_date_free(event->end_date); if(event->date_string != NULL) g_free(event->date_string); if(event->start_time != NULL) g_free(event->start_time); if(event->end_time != NULL) g_free(event->end_time); if(event->file_name != NULL) g_free(event->file_name); if(event->key != NULL) g_free(event->key); g_free(event); event = NULL; return; } static gboolean is_valid_todo(const gchar* date_string) { if( strcmp(date_string, "TODO") == 0 ) return TRUE; return FALSE; } static gboolean get_key_todo(const GDate* date, gchar *buffer) { GDate* today = g_date_new(); g_date_set_time_t(today, time(NULL)); if(g_date_days_between(today, date) != 0) { g_date_free(today); return FALSE; } g_date_free(today); strcpy( buffer, "TODO" ); return TRUE; } static gchar *get_descr_todo(const GDate *date) { (void)date; /* Avoid unused warning */ return g_strdup("TODO event"); } static gboolean is_valid_daily(const gchar* date_string) { if( strcmp(date_string, "DAILY") == 0 ) return TRUE; return FALSE; } static gboolean get_key_daily(const GDate* date, gchar *buffer) { (void)date; /* Avoid unused warning */ strcpy( buffer, "DAILY" ); return TRUE; } static gchar *get_descr_daily(const GDate *date) { (void)date; /* Avoid unused warning */ return g_strdup("Daily"); } static gboolean is_valid_yyyymmdd(const gchar* date_string) { gint d[8]; /* if key is regular event in the form: single day, monthly, yearly, yearly/monthly */ if(sscanf(date_string, "%1d%1d%1d%1d%1d%1d%1d%1d", &d[0],&d[1],&d[2],&d[3],&d[4],&d[5],&d[6],&d[7]) == 8) { gint year, month, day; year = d[0] * 1000 + d[1] * 100 + d[2] * 10 + d[3]; month = d[4] * 10 + d[5]; day = d[6] * 10 + d[7]; if(day < 1 || day > 31 || month < 1 || month > 12 || year < 1) return FALSE; /* FIXME: Don't allow one-time events on leap day in years * that leap day doesn't exist */ if(month == 2 && day > 29) return FALSE; /* 30 days in april, june, sept, nov */ if((month == 4 || month == 6 || month == 9 || month == 11) && day > 30) return FALSE; /* make sure there weren't more characters that sscanf didn't see */ if(strlen(date_string) == 8) return TRUE; } return FALSE; } static gboolean get_key_yyyymmdd(const GDate* date, gchar *buffer) { snprintf(buffer, 9, "%04d%02d%02d", g_date_get_year(date), g_date_get_month(date), g_date_get_day(date)); return TRUE; } static gchar *get_descr_yyyymmdd(const GDate* date) { char buf[128]; char *ptr; ptr = strcpy( buf, "Only on " ); g_date_strftime(ptr, 100, settings->date_fmt, date); return g_strdup(buf); } static const gchar *day_names[8] = { /*[0] =*/ "", /*[1] =*/ "MON", /*[2] =*/ "TUE", /*[3] =*/ "WED", /*[4] =*/ "THU", /*[5] =*/ "FRI", /*[6] =*/ "SAT", /*[7] =*/ "SUN" }; static gboolean is_valid_weekly(const gchar* date_string) { int i; for( i=1; i<=7; i++ ) if( strcmp( date_string, day_names[i] ) == 0 ) return TRUE; return FALSE; } static gboolean get_key_weekly(const GDate* date, gchar* buffer) { strcpy( buffer, day_names[ g_date_get_weekday(date) ] ); return TRUE; } static gchar *get_descr_weekly(const GDate* date) { char buf[128]; g_date_strftime(buf, 128, "Weekly: Every %A", date); return g_strdup(buf); } static gboolean is_valid_000000dd(const gchar* date_string) { gint d[8]; if(sscanf(date_string, "000000%1d%1d", &d[6],&d[7]) == 2) { int day = d[6] * 10 + d[7]; if(day < 1 || day > 31) return FALSE; if(strlen(date_string) == 8) return TRUE; } return FALSE; } static gboolean get_key_000000dd(const GDate* date, gchar* buffer) { snprintf( buffer, MAX_KEYLEN, "000000%02d", g_date_get_day(date) ); return TRUE; } static gchar *get_descr_000000dd(const GDate* date) { char buf[128]; snprintf( buf, 128, "Monthly: Day %d of every month", g_date_get_day(date) ); return g_strdup(buf); } static gboolean is_valid_0000mmdd(const gchar* date_string) { gint d[8]; if(sscanf(date_string, "0000%1d%1d%1d%1d", &d[4],&d[5],&d[6],&d[7]) == 4) { gint month, day; day = d[6] * 10 + d[7]; month = d[4] * 10 + d[5]; if(day < 1 || day > 31 || month < 1 || month > 12) return FALSE; /* FIXME: Don't allow one-time events on leap day in years * that leap day doesn't exist */ if(month == 2 && day > 29) return FALSE; /* 30 days in april, june, sept, nov */ if((month == 4 || month == 6 || month == 9 || month == 11) && day > 30) return FALSE; if(strlen(date_string) == 8) return TRUE; } return FALSE; } static gboolean get_key_0000mmdd(const GDate* date, gchar* buffer) { snprintf( buffer, MAX_KEYLEN, "0000%02d%02d", g_date_get_month(date), g_date_get_day(date) ); return TRUE; } static gchar *get_descr_0000mmdd(const GDate* date) { char buf1[128]; char buf2[128]; g_date_strftime(buf1, 128, "%B", date); snprintf( buf2, 128, "Annually: %d %s", g_date_get_day(date), buf1 ); return g_strdup(buf2); } static gboolean is_valid_star_00nd(const gchar* date_string) { gint d[2]; if(sscanf(date_string, "*00%1d%1d", &d[0],&d[1]) == 2) /* nth weekday of month */ { gint n, weekday; n = d[0]; weekday = d[1]; if(weekday > 0 && weekday < 8 && n > 0 && n < 6) /* no more than 5 weeks in a month */ { if(strlen(date_string) == 5) return TRUE; } } return FALSE; } static gboolean get_key_star_00nd(const GDate* date, gchar* buffer) { /* convert weekday to friendly weekday from: 1(mon) -> 7(sun) to: 1(sun) -> 7(sat) */ int weekday = (g_date_get_weekday(date) % 7) + 1; snprintf( buffer, MAX_KEYLEN, "*00%d%d", get_nth_day(date), weekday ); return TRUE; } static gchar *get_descr_star_00nd(const GDate* date) { char suffix[16]; char buf1[128]; char buf2[128]; pal_add_suffix(get_nth_day(date), suffix, 16); g_date_strftime(buf1, 128, "%A", date); snprintf(buf2, 128, "Monthly: The %s %s of every month", suffix, buf1); return g_strdup(buf2); } static gboolean is_valid_star_mmnd(const gchar* date_string) { gint d[8]; if(sscanf(date_string, "*%1d%1d%1d%1d", &d[0],&d[1],&d[2],&d[3]) == 4) /* nth weekday of month */ { gint month, n, weekday; month = d[0] * 10 + d[1]; n = d[2]; weekday = d[3]; if(weekday > 0 && weekday < 8 && month > 0 && month < 13 && n > 0 && n < 6) /* no more than 5 weeks in a month */ { if(strlen(date_string) == 5) return TRUE; } } return FALSE; } static gboolean get_key_star_mmnd(const GDate* date, gchar* buffer) { /* convert weekday to friendly weekday from: 1(mon) -> 7(sun) to: 1(sun) -> 7(sat) */ int weekday = (g_date_get_weekday(date) % 7) + 1; snprintf( buffer, MAX_KEYLEN, "*%02d%d%d", g_date_get_month(date), get_nth_day(date), weekday ); return TRUE; } static gchar *get_descr_star_mmnd(const GDate* date) { char suffix[16]; char buf1[128]; char buf2[128]; char buf3[128]; pal_add_suffix(get_nth_day(date), suffix, 16); g_date_strftime(buf1, 128, "%A", date); g_date_strftime(buf2, 128, "%B", date); snprintf(buf3, 128, "Annually: The %s %s of every %s", suffix, buf1, buf2); return g_strdup(buf3); } static gboolean is_valid_star_00Ld(const gchar* date_string) { gint d[2]; if(sscanf(date_string, "*00L%1d", &d[0]) == 1) /* last weekday of month */ { gint weekday; weekday = d[0]; if(weekday > 0 && weekday < 8) { if(strlen(date_string) == 5) return TRUE; } } return FALSE; } static gboolean get_key_star_00Ld(const GDate* date, gchar* buffer) { int weekday; if( !last_weekday_of_month(date) ) return FALSE; /* convert weekday to friendly weekday from: 1(mon) -> 7(sun) to: 1(sun) -> 7(sat) */ weekday = (g_date_get_weekday(date) % 7) + 1; snprintf( buffer, MAX_KEYLEN, "*00L%d", weekday ); return TRUE; } static gchar *get_descr_star_00Ld(const GDate* date) { char buf1[128]; char buf2[128]; if( !last_weekday_of_month(date) ) return NULL; g_date_strftime(buf1, 128, "%A", date); snprintf(buf2, 128, "Monthly: The last %s of every month", buf1); return g_strdup(buf2); } static gboolean is_valid_star_mmLd(const gchar* date_string) { gint d[8]; if(sscanf(date_string, "*%1d%1dL%1d", &d[0],&d[1],&d[2]) == 3) /* last weekday of month */ { gint month, weekday; month = d[0] * 10 + d[1]; weekday = d[2]; if(weekday > 0 && weekday < 8 && month > 0 && month < 13 ) { if(strlen(date_string) == 5) return TRUE; } } return FALSE; } static gboolean get_key_star_mmLd(const GDate* date, gchar* buffer) { int weekday; if( !last_weekday_of_month(date) ) return FALSE; /* convert weekday to friendly weekday from: 1(mon) -> 7(sun) to: 1(sun) -> 7(sat) */ weekday = (g_date_get_weekday(date) % 7) + 1; snprintf( buffer, MAX_KEYLEN, "*%02dL%d", g_date_get_month(date), weekday ); return TRUE; } static gchar *get_descr_star_mmLd(const GDate* date) { char buf1[128]; char buf2[128]; char buf3[128]; if( !last_weekday_of_month(date) ) return NULL; g_date_strftime(buf1, 128, "%A", date); g_date_strftime(buf2, 128, "%B", date); snprintf(buf3, 128, "Annually: The last %s of every %s", buf1, buf2); return g_strdup(buf3); } static gboolean is_valid_EASTER(const gchar* date_string) { if(strncmp(date_string, "EASTER", 6) == 0) { if(strlen(date_string) == 6) return TRUE; if(date_string[6] == '-' || date_string[6] == '+') { if(g_ascii_isdigit(date_string[7]) && g_ascii_isdigit(date_string[8]) && g_ascii_isdigit(date_string[9])) { if(date_string[10] == '\0') return TRUE; } } } return FALSE; } /* checks if date_string is a valid date string. Before calling this * function, g_strstrip needs to be called on date_string! g_ascii_strup * should also be called on the date_string. */ gboolean parse_event( PalEvent *event, const gchar* date_string) { gchar** s; gchar* ptr; int count = 1; int i; PalPeriodic period = PAL_ONCEONLY; s = g_strsplit(date_string, ":", 3); do { /* Loop to break out of for failure so we can clean up */ if( s[1] && !is_valid_yyyymmdd(s[1]) ) /* start date */ break; /* Need to check both, if s[1] is NULL, s[2] isn't valid */ if( s[1] && s[2] && !is_valid_yyyymmdd(s[2]) ) /* end date */ break; if( (ptr = strrchr( s[0], '/' )) != NULL ) /* Repeat counter */ { if( sscanf( ptr+1, "%d%*s", &count ) != 1 || count < 1 ) /* Invalid count */ break; *ptr = '\0'; } for( i=0; i < PAL_NUM_EVENTTYPES; i++ ) { if( PalEventTypes[i].valid_string( s[0] ) ) { period = PalEventTypes[i].period; break; } } if( i == PAL_NUM_EVENTTYPES ) break; /* Fail */ /* We now know the string is valid */ if(s[1]) { event->start_date = get_date(s[1]); if( s[2] ) event->end_date = get_date(s[2]); else event->end_date = g_date_new_dmy(1,1,3000); } event->period_count = count; event->eventtype = &PalEventTypes[i]; event->key = g_strdup( s[0] ); g_strfreev(s); return TRUE; } while(0); g_strfreev(s); return FALSE; } static GDate* find_easter(gint year) { gint a,b,c,d,e,f,g,h,i,k,l,m,p,month,day; a = year%19; b = year/100; c = year%100; d = b/4; e = b%4; f = (b+8) / 25; g = (b-f+1) / 3; h = (19*a+b-d-g+15) % 30; i = c/4; k = c%4; l = (32+2*e+2*i-h-k)%7; m = (a+11*h+22*l) / 451; month = (h+l-7*m+114) / 31; p = (h+l-7*m+114) % 31; day = p+1; return g_date_new_dmy((GDateDay) day, (GDateMonth) month, (GDateYear) year); } static gboolean get_key_EASTER(const GDate* date, gchar *buffer) { GDate* easter = find_easter(g_date_get_year(date)); gint diff = g_date_days_between(date,easter); g_date_free(easter); if(diff != 0) snprintf(buffer, 12, "EASTER%c%03d", (diff > 0) ? '-' : '+', (diff > 0) ? diff : -diff); else snprintf(buffer, 12, "EASTER"); return TRUE; } static gchar *get_descr_EASTER(const GDate* date) { char buf[128]; GDate* easter = find_easter(g_date_get_year(date)); gint diff = g_date_days_between(date,easter); g_date_free(easter); if(diff != 0) snprintf(buf, 128, "%d days %s Easter", (diff > 0) ? diff : -diff, (diff > 0) ? "before" : "after"); else snprintf(buf, 128, "Easter"); return g_strdup(buf); } /* gets the yyyymmdd key for the given date. The returned string * should be freed. */ gchar* get_key(const GDate* date) { gchar* key = g_malloc(sizeof(gchar)*9); snprintf(key, 9, "%04d%02d%02d", g_date_get_year(date), g_date_get_month(date), g_date_get_day(date)); return key; } /* this only works on dates in yyyymmdd format. It ignores everything * after the 8th character. The returned GDate object should be * freed. Returns NULL on failure*/ GDate* get_date(const gchar* key) { GDate* date = NULL; gint year, month, day; sscanf(key, "%04d%02d%02d", &year, &month, &day); if(g_date_valid_dmy((GDateDay) day, (GDateMonth) month, (GDateYear) year)) date = g_date_new_dmy((GDateDay) day, (GDateMonth) month, (GDateYear) year); return date; } static gboolean last_weekday_of_month(const GDate* date) { GDate* local = g_memdup(date,sizeof(GDate)); g_date_add_days(local,7); if(g_date_get_month(local) != g_date_get_month(date)) { g_date_free(local); return TRUE; } g_date_free(local); return FALSE; } /* Returns n from date --- as in: "date" is the "n"th * sunday/monday/... of the month */ static gint get_nth_day(const GDate* date) { int i = (g_date_get_day(date) / 7) + 1; if(g_date_get_day(date) % 7 == 0) i--; return i; } /* removes events from the list whose range that are does not include * "date". Also remove recurring events that should be skipped for * the given date. * * Returns the beginning of the new list (it might have changed) */ static GList* inspect_range(GList* list, const GDate* date) { GList* item = list; if(list == NULL) return list; while(g_list_length(item) > 0) { gboolean remove = FALSE; PalEvent *event = (PalEvent*) item->data; if(event->start_date != NULL && event->end_date != NULL) { if(g_date_days_between(date, event->start_date) > 0 || g_date_days_between(date, event->end_date) < 0) remove = TRUE; else if( event->period_count != 1 ) { int event_count = 0; /* Number of times event has happened since start */ switch( event->eventtype->period ) { case PAL_ONCEONLY: event_count = 1; break; case PAL_DAILY: event_count = g_date_days_between(event->start_date, date); break; case PAL_WEEKLY: event_count = g_date_days_between(event->start_date, date) / 7; break; case PAL_MONTHLY: { int month_start = g_date_get_month(event->start_date) + 12*g_date_get_year(event->start_date); int month_cur = g_date_get_month(date) + 12*g_date_get_year(date); event_count = month_cur - month_start; break; } case PAL_YEARLY: { event_count = g_date_get_year(date) - g_date_get_year(event->start_date); break; } } if( (event_count % event->period_count) != 0 ) remove = TRUE; } if( remove ) { /* if not on last item */ if(g_list_length(item) > 1) { /* save reference to next data item */ gpointer n = g_list_next(item)->data; /* remove this list element */ list = g_list_remove(list, item->data); /* find what we need to look at next */ item = g_list_find(list, n); } else /* we're on last item */ { list = g_list_remove(list, item->data); item = g_list_last(list); } } else item = g_list_next(item); } else item = g_list_next(item); } return list; } static gint pal_event_sort_fn(gconstpointer x, gconstpointer y) { PalEvent* a = (PalEvent*) x; PalEvent* b = (PalEvent*) y; /* Put events with start times before events without start times */ if(a->start_time != NULL && b->start_time == NULL) return 1; if(a->start_time == NULL && b->start_time != NULL) return -1; /* if both events have start times, sort by start time */ if(a->start_time != NULL && b->start_time != NULL) { if(a->start_time->hour < b->start_time->hour) return -1; if(a->start_time->hour > b->start_time->hour) return 1; /* if we get here, the hours are the same */ if(a->start_time->min < b->start_time->min) return -1; if(a->start_time->min > b->start_time->min) return 1; return 0; } /* if neither event has start times, sort by order in pal.conf */ if(a->file_num == b->file_num) return 0; if(a->file_num < b->file_num) return -1; else return 1; } static GList* pal_event_sort_events(GList* events) { if(events == NULL) return NULL; return g_list_sort(events, pal_event_sort_fn); } /* Returns a list of events on the given date. The returned list is sorted. */ GList* get_events(const GDate* date) { GList* list = NULL; GList* days_events = NULL; gchar eventkey[MAX_KEYLEN]; int i; for( i=0; i < PAL_NUM_EVENTTYPES; i++ ) { if( PalEventTypes[i].get_key( date, eventkey ) == FALSE ) continue; days_events = g_hash_table_lookup(ht,eventkey); if(days_events != NULL) list = g_list_concat(list, g_list_copy(days_events)); } list = inspect_range(list, date); list = pal_event_sort_events(list); return list; } /* Some places only need to know the number of events on a day. They should * use this instead to avoid leaking memory when doing g_list_length(get_events) */ gint pal_get_event_count( GDate *date ) { GList *events = get_events( date ); gint count = g_list_length(events); g_list_free(events); return count; } /* the returned string should be freed */ gchar* pal_event_escape(const PalEvent* event, const GDate* today) { gchar* in = event->text; gchar* out_string = g_malloc(sizeof(gchar)*strlen(event->text)*2); gchar* out = out_string; while(*in != '\0') { if( *in == '!' && strlen(in) > 5 && g_ascii_isdigit(*(in+1)) && g_ascii_isdigit(*(in+2)) && g_ascii_isdigit(*(in+3)) && g_ascii_isdigit(*(in+4)) && *(in+5) == '!') { int diff; int now = g_date_get_year(today); int event = g_ascii_digit_value(*(in+1)); event *= 10; event += g_ascii_digit_value(*(in+2)); event *= 10; event += g_ascii_digit_value(*(in+3)); event *= 10; event += g_ascii_digit_value(*(in+4)); diff = now-event; out += sprintf(out, "%i", diff); in += 6; } else { *out = *in; out++; in++; } } *out = '\0'; return out_string; } PalEventType PalEventTypes[] = { /* todo */ { PAL_ONCEONLY, is_valid_todo, get_key_todo, get_descr_todo }, /* single day event */ { PAL_ONCEONLY, is_valid_yyyymmdd, get_key_yyyymmdd, get_descr_yyyymmdd }, /* daily event */ { PAL_DAILY, is_valid_daily, get_key_daily, get_descr_daily }, /* weekly event */ { PAL_WEEKLY, is_valid_weekly, get_key_weekly, get_descr_weekly }, /* monthly event */ { PAL_MONTHLY, is_valid_000000dd, get_key_000000dd, get_descr_000000dd }, /* monthly event Nth something-day */ { PAL_MONTHLY, is_valid_star_00nd, get_key_star_00nd, get_descr_star_00nd }, /* yearly event */ { PAL_YEARLY, is_valid_0000mmdd, get_key_0000mmdd, get_descr_0000mmdd }, /* yearly event on Nth something-day of a certain month */ { PAL_YEARLY, is_valid_star_mmnd, get_key_star_mmnd, get_descr_star_mmnd }, /* monthly event on the last something-day */ { PAL_MONTHLY, is_valid_star_00Ld, get_key_star_00Ld, get_descr_star_00Ld }, /* yearly event on the last something-day */ { PAL_YEARLY, is_valid_star_mmLd, get_key_star_mmLd, get_descr_star_mmLd }, /* easter */ { PAL_YEARLY, is_valid_EASTER, get_key_EASTER, get_descr_EASTER } }; const gint PAL_NUM_EVENTTYPES = sizeof(PalEventTypes) / sizeof(PalEventTypes[0]); pal-0.4.3/src/manage.h0000644000175000017500000000151111043370327014354 0ustar kleptogkleptog#ifndef PAL_MANAGE_H #define PAL_MANAGE_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ void pal_manage(void); #endif pal-0.4.3/src/add.h0000644000175000017500000000166111043370327013662 0ustar kleptogkleptog#ifndef PAL_ADD_H #define PAL_ADD_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ void pal_add_event(GDate *); gchar* pal_add_get_date_recur(void); void pal_add_write_file(gchar* filename, gchar* key, gchar* desc); #endif pal-0.4.3/src/colorize.h0000644000175000017500000000276411043370327014765 0ustar kleptogkleptog#ifndef PAL_COLORIZE_H #define PAL_COLORIZE_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include /* attributes */ #define RESET 0 #define BRIGHT 1 #define DIM 2 #define UNDERLINE 3 #define BLINK 4 #define REVERSE 7 #define HIDDEN 8 /* colors */ #define BLACK 0 #define RED 1 #define GREEN 2 #define YELLOW 3 #define BLUE 4 #define MAGENTA 5 #define CYAN 6 #define WHITE 7 void colorize_xterm_title(gchar *title); void set_colorize(const int in); void colorize_fg(const int attribute, const int foreground); void colorize_reset(void); void colorize_bright(void); void colorize_error(void); gchar* string_color_of(const int color); int int_color_of(gchar* string); #ifdef CURSES extern WINDOW *pal_curwin; #endif #endif pal-0.4.3/src/rl.h0000644000175000017500000000274111043370327013547 0ustar kleptogkleptog#ifndef PAL_RL_H #define PAL_RL_H /* pal * * Copyright (C) 2004--2006, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include /* extern char* pal_rl_default_text; */ char* pal_rl_no_match(void); /* can't return blank line */ gchar* pal_rl_get_line(const char* prompt, const int row, const int col); gchar* pal_rl_get_line_default(const char* prompt, const int row, const int col, const char* default_text); /* can return blank line */ gchar* pal_rl_get_raw_line(const char* prompt, const int row, const int col); gboolean pal_rl_get_y_n(const char* prompt); /* void pal_rl_default_text_fn(void); */ void pal_rl_completions_output(char **matches, int num_matches, int max_length ); PalEvent* pal_rl_get_event(GDate** d, gboolean allow_global); void pal_rl_ncurses_hack(void); #endif pal-0.4.3/src/main.c0000644000175000017500000005726111043370327014060 0ustar kleptogkleptog/* pal * * Copyright (C) 2004--2006, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include /* get # columns for terminal */ #include #include #include #include /* FreeBSD, regex.h needs this */ #include /* regular expressions */ #include #include #include "output.h" #include "main.h" #include "input.h" #include "event.h" #include "rl.h" #include "html.h" #include "latex.h" #include "search.h" #include "manage.h" Settings* settings; GHashTable* ht; /* ht holds the loaded events */ /* prints the events on the dates from the starting_date to * starting_date+window */ static void view_range(GDate* starting_date, gint window) { gint i; if(settings->reverse_order) g_date_add_days(starting_date,window-1); for(i=0; ireverse_order) g_date_subtract_days(starting_date,1); else g_date_add_days(starting_date,1); } } /* Returns a GDate object for the given key (in_string) */ /* This function only checks the one-time date events (not todo, or * recurring events). It returns NULL on a failure and can optionally * print an error message on failure. */ GDate* get_query_date(gchar* in_string, gboolean show_error) { GDate* to_show = NULL; gchar* date_string = g_ascii_strdown(in_string, -1); if(date_string == NULL) return NULL; g_strstrip(date_string); to_show = g_date_new(); g_date_set_time_t(to_show, time(NULL)); /* these could be better... */ if(strncmp(date_string, _("tomorrow"), strlen(_("tomorrow"))) == 0) { g_date_add_days(to_show, 1); g_free(date_string); return to_show; } if(strncmp(date_string, _("yesterday"), strlen(_("yesterday"))) == 0) { g_date_subtract_days(to_show, 1); g_free(date_string); return to_show; } if(strncmp(date_string, _("today"), strlen(_("today"))) == 0) { g_date_subtract_days(to_show, 0); g_free(date_string); return to_show; } if(strncmp(date_string, _("mo"), strlen(_("mo"))) == 0 || strncmp(date_string, _("next mo"), strlen(_("next mo"))) == 0) { do g_date_add_days(to_show, 1); while(g_date_get_weekday(to_show) != 1); g_free(date_string); return to_show; } if(strncmp(date_string, _("tu"), strlen(_("tu"))) == 0 || strncmp(date_string, _("next tu"), strlen(_("next tu"))) == 0) { do g_date_add_days(to_show, 1); while(g_date_get_weekday(to_show) != 2); g_free(date_string); return to_show; } if(strncmp(date_string, _("we"), strlen(_("we"))) == 0 || strncmp(date_string, _("next we"), strlen(_("next we"))) == 0) { do g_date_add_days(to_show, 1); while(g_date_get_weekday(to_show) != 3); g_free(date_string); return to_show; } if(strncmp(date_string, _("th"), strlen(_("th"))) == 0 || strncmp(date_string, _("next th"), strlen(_("next th"))) == 0) { do g_date_add_days(to_show, 1); while(g_date_get_weekday(to_show) != 4); g_free(date_string); return to_show; } if(strncmp(date_string, _("fr"), strlen(_("fr"))) == 0 || strncmp(date_string, _("next fr"), strlen(_("next fr"))) == 0) { do g_date_add_days(to_show, 1); while(g_date_get_weekday(to_show) != 5); g_free(date_string); return to_show; } if(strncmp(date_string, _("sa"), strlen(_("sa"))) == 0 || strncmp(date_string, _("next sa"), strlen(_("next sa"))) == 0) { do g_date_add_days(to_show, 1); while(g_date_get_weekday(to_show) != 6); return to_show; } if(strncmp(date_string, _("su"), strlen(_("su"))) == 0 || strncmp(date_string, _("next su"), strlen(_("next su"))) == 0) { do g_date_add_days(to_show, 1); while(g_date_get_weekday(to_show) != 7); g_free(date_string); return to_show; } if(strncmp(date_string, _("last mo"), strlen(_("last mo"))) == 0) { do g_date_subtract_days(to_show, 1); while(g_date_get_weekday(to_show) != 1); g_free(date_string); return to_show; } if(strncmp(date_string, _("last tu"), strlen(_("last tu"))) == 0) { do g_date_subtract_days(to_show, 1); while(g_date_get_weekday(to_show) != 2); g_free(date_string); return to_show; } if(strncmp(date_string, _("last we"), strlen(_("last we"))) == 0) { do g_date_subtract_days(to_show, 1); while(g_date_get_weekday(to_show) != 3); g_free(date_string); return to_show; } if(strncmp(date_string, _("last th"), strlen(_("last th"))) == 0) { do g_date_subtract_days(to_show, 1); while(g_date_get_weekday(to_show) != 4); g_free(date_string); return to_show; } if(strncmp(date_string, _("last fr"), strlen(_("last fr"))) == 0) { do g_date_subtract_days(to_show, 1); while(g_date_get_weekday(to_show) != 5); g_free(date_string); return to_show; } if(strncmp(date_string, _("last sa"), strlen(_("last sa"))) == 0) { do g_date_subtract_days(to_show, 1); while(g_date_get_weekday(to_show) != 6); g_free(date_string); return to_show; } if(strncmp(date_string, _("last su"), strlen(_("last su"))) == 0) { do g_date_subtract_days(to_show, 1); while(g_date_get_weekday(to_show) != 7); g_free(date_string); return to_show; } /* use regexs here for easier localization */ { regex_t preg; regcomp(&preg, _("^[0-9]+ days away$"), REG_ICASE|REG_NOSUB|REG_EXTENDED); if(regexec(&preg, date_string, 0, NULL, 0)==0) { gchar* ptr = date_string; gint date_offset = 0; while(!g_ascii_isdigit(*ptr) && ptr != NULL) ptr = g_utf8_find_next_char(ptr, NULL); sscanf(ptr, "%d", &date_offset); g_date_add_days(to_show, date_offset); g_free(date_string); regfree(&preg); return to_show; } regfree(&preg); regcomp(&preg, _("^[0-9]+ days ago$"), REG_ICASE|REG_NOSUB|REG_EXTENDED); if(regexec(&preg, date_string, 0, NULL, 0)==0) { gchar* ptr = date_string; gint date_offset = 0; while(!g_ascii_isdigit(*ptr) && ptr != NULL) ptr = g_utf8_find_next_char(ptr, NULL); sscanf(ptr, "%d", &date_offset); g_date_subtract_days(to_show, date_offset); g_free(date_string); regfree(&preg); return to_show; } regfree(&preg); } if(g_ascii_isdigit(*(date_string))) /* if it begins with a digit ... */ { gchar* ptr = date_string; while(g_ascii_isdigit(*ptr)) ptr++; /* ... and if the string is entirely made up of digits */ if(*ptr == '\0') { gint query_date_int = -1; sscanf(date_string, "%d", &query_date_int); /* check for 0, negative number, or excessive preceeding 0's */ if(!(query_date_int <= 0 || (*date_string == '0' && *(date_string+1) == '0' && *(date_string+2) == '0' && *(date_string+3) == '0') || (*(date_string+4) == '0' && *(date_string+5) == '0') || (*(date_string+6) == '0' && *(date_string+7) == '0'))) { if(query_date_int < 32) { if(query_date_int < g_date_get_day(to_show)) g_date_add_months(to_show,1); if(g_date_valid_dmy(query_date_int, (GDateMonth) g_date_get_month(to_show), (GDateYear) g_date_get_year(to_show))) { g_date_set_day(to_show, query_date_int); g_free(date_string); return to_show; } } else if(query_date_int < 1232) { gint day, month; day = query_date_int % 100; month = query_date_int / 100; if(day > 0 && day < 32 && month > 0 && month < 13) { if(month < g_date_get_month(to_show)) g_date_add_years(to_show,1); if(day < g_date_get_day(to_show) && month == g_date_get_month(to_show)) g_date_add_years(to_show, 1); if(g_date_valid_dmy((GDateDay) day, (GDateMonth) month, (GDateYear) g_date_get_year(to_show))) { g_date_set_dmy(to_show, (GDateDay) day, (GDateMonth) month, (GDateYear) g_date_get_year(to_show)); g_free(date_string); return to_show; } } } else if(query_date_int > 10000) { gint day, month, year; day = query_date_int % 100; month = (query_date_int % 10000 - day) / 100; year = query_date_int / 10000; if(day > 0 && day < 32 && month > 0 && month < 13 && year > 0) { if(g_date_valid_dmy((GDateDay) day, (GDateMonth) month, (GDateYear) year)) { g_date_set_dmy(to_show, (GDateDay) day, (GDateMonth) month, (GDateYear) year); g_free(date_string); return to_show; } } } } } } /* glib is last resort, but don't let a few things get to it... */ if(!((*date_string == '0' && *(date_string+1) == '0' && *(date_string+2) == '0' && *(date_string+3) == '0') || (*(date_string+4) == '0' && *(date_string+5) == '0') || (*(date_string+6) == '0' && *(date_string+7) == '0'))) { g_date_set_parse(to_show, date_string); if(g_date_valid(to_show)) { g_free(date_string); return to_show; } } if(show_error) { /* if we got here, there was an error */ pal_output_error(_("ERROR: The following date is not valid: %s\n"), date_string); pal_output_error( " %s\n", _("Valid date formats include:")); pal_output_error( " %s '%s', '%s', '%s',\n", _("dd, mmdd, yyyymmdd,"), _("yesterday"), _("today"), _("tomorrow")); pal_output_error( " %s\n", _("'n days away', 'n days ago',")); pal_output_error( " %s\n", _("first two letters of weekday,")); pal_output_error( " %s\n", _("'next ' followed by first two letters of weekday,")); pal_output_error( " %s\n", _("'last ' followed by first two letters of weekday,")); pal_output_error( " %s\n", _("'1 Jan 2000', 'Jan 1 2000', etc.")); } g_date_free(to_show); g_free(date_string); return NULL; } /* determines what should be dispalyed if -r, -s, -d are used */ static void view_details(void) { GDate* to_show = settings->query_date; if(settings->search_string != NULL && settings->range_days == 0 && settings->range_neg_days == 0) { g_print("\n"); pal_output_fg(BRIGHT, RED, "> "); pal_output_wrap(_("NOTE: You can use -r to specify the range of days to search. By default, pal searches days within one year of today."),2,2); settings->range_days = 365; } /* if -r and -s isn't used */ if(settings->range_days == 0 && settings->range_neg_days == 0 && settings->search_string == NULL) { /* if -d is used, show that day. Otherwise, show nothing */ if(to_show != NULL) pal_output_date(to_show, TRUE, -1); } /* if -r or -s is used, show range of dates relative to -d */ else if(settings->range_days != 0 || settings->range_neg_days != 0) { GDate* starting_date = NULL; if(to_show == NULL) /* if -d isn't used, start from current date */ { starting_date = g_date_new(); g_date_set_time_t(starting_date, time(NULL)); } else /* otherwise, start from date specified */ starting_date = g_memdup(to_show, sizeof(GDate)); g_date_subtract_days(starting_date, settings->range_neg_days); if(settings->search_string == NULL) view_range(starting_date, settings->range_neg_days + settings->range_days); else pal_search_view(settings->search_string, starting_date, settings->range_neg_days + settings->range_days, FALSE); g_date_free(starting_date); } } static gint parse_arg(gchar** args, gint on_arg, gint total_args) { args = args + on_arg; on_arg++; if(strcmp(*args,"-h") == 0 || strcmp(*args,"--help") == 0) { g_print("%s %s - %s\n", "pal", PAL_VERSION, _("Copyright (C) 2006, Scott Kuhl")); g_print(" "); pal_output_wrap(_("pal is licensed under the GNU General Public License and has NO WARRANTY."), 2, 2); g_print("\n"); pal_output_wrap(_(" -d date Show events on the given date. Valid formats for date include: dd, mmdd, yyyymmdd, 'Jan 1 2000'. Run 'man pal' for a list of all valid formats."), 0, 16); pal_output_wrap(_(" -r n Display events within n days after today or a date used with -d. (default: n=0, show nothing)"), 0, 16); pal_output_wrap(_(" -r p-n Display events within p days before and n days after today or a date used with -d."), 0, 16); pal_output_wrap(_(" -s regex Search for events matching the regular expression. Use -r to select range of days to search."), 0, 16); pal_output_wrap(_(" -x n Expunge events that are n or more days old."), 0, 16); pal_output_wrap(_(" -c n Display calendar with n lines. (default: 5)"), 0, 16); pal_output_wrap(_(" -f file Load 'file' instead of ~/.pal/pal.conf"), 0, 16); pal_output_wrap(_(" -u username Load /home/username/.pal/pal.conf"), 0, 16); pal_output_wrap(_(" -p palfile Load *.pal file only (overrides files loaded from pal.conf)"), 0, 16); pal_output_wrap(_(" -m Add/Modify/Delete events interactively."), 0, 16); pal_output_wrap(_(" --color Force colors, regardless of terminal type."), 0, 16); pal_output_wrap(_(" --nocolor Force no colors, regardless of terminal type."), 0, 16); pal_output_wrap(_(" --mail Generate output readable by sendmail."), 0, 16); pal_output_wrap(_(" --html Generate HTML calendar. Set size of calendar with -c."), 0, 16); pal_output_wrap(_(" --latex Generate LaTeX calendar. Set size of calendar with -c."), 0, 16); pal_output_wrap(_(" -v Verbose output."), 0, 16); pal_output_wrap(_(" --version Display version information."), 0, 16); pal_output_wrap(_(" -h, --help Display this help message."), 0, 16); g_print("\n"); pal_output_wrap(_("Type \"man pal\" for more information."), 0, 16); exit(0); } if(strcmp(*args,"-r") == 0) { args++; on_arg++; if(on_arg > total_args || (sscanf(*args, "%d", &(settings->range_days)) != 1 && sscanf(*args, "%d-%d", &(settings->range_neg_days), &(settings->range_days)) != 2)) { settings->range_days = 0; settings->range_neg_days = 0; pal_output_error("%s\n", _("ERROR: Number required after -r argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); return on_arg-1; } settings->range_arg = TRUE; if(sscanf(*args, "%d-%d", &(settings->range_neg_days), &(settings->range_days)) == 2) return on_arg; if(sscanf(*args, "%d", &(settings->range_days)) == 1) { settings->range_neg_days = 0; return on_arg; } return on_arg; } if(strcmp(*args,"-c") == 0) { args++; on_arg++; if(on_arg > total_args || sscanf(*args, "%d", &(settings->cal_lines)) != 1) { pal_output_error("%s\n", _("ERROR: Number required after -c argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); on_arg--; } return on_arg; } if(strcmp(*args,"-d") == 0) { args++; on_arg++; if(on_arg > total_args) { pal_output_error("%s\n", _("ERROR: Date required after -d argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); on_arg--; } else { gchar *utf8arg = g_locale_to_utf8(*args, -1, NULL, NULL, NULL); settings->query_date = get_query_date(utf8arg, TRUE); g_free(utf8arg); if(settings->query_date == NULL) pal_output_error(_("NOTE: Use quotes around the date if it has spaces.\n")); } return on_arg; } if(strcmp(*args,"-v") == 0) { settings->verbose = TRUE; return on_arg; } if(strcmp(*args,"-a") == 0) { settings->manage_events = TRUE; pal_output_error(_("WARNING: -a is deprecated, use -m instead.\n")); return on_arg; } if(strcmp(*args,"-m") == 0) { settings->manage_events = TRUE; return on_arg; } if(strcmp(*args,"--color") == 0) { set_colorize(1); return on_arg; } if(strcmp(*args,"--nocolor") == 0) { set_colorize(0); return on_arg; } if(strcmp(*args,"--mail") == 0) { set_colorize(-2); /* overrides a later --color argument */ settings->mail = TRUE; return on_arg; } if(strcmp(*args,"--html") == 0) { settings->html_out = TRUE; return on_arg; } if(strcmp(*args, "--latex") == 0) { settings->latex_out = TRUE; return on_arg; } if(strcmp(*args,"--version") == 0) { g_print("pal %s\n", PAL_VERSION); g_print(_("Compiled with prefix: %s\n"), PREFIX); exit(0); } if(strcmp(*args,"-f") == 0) { gchar tmp[16384]; args++; on_arg++; if(on_arg > total_args || sscanf(*args, "%s", tmp) != 1) { pal_output_error("%s\n", _("ERROR: Pal conf file required after -f argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); return on_arg; } g_free(settings->conf_file); settings->conf_file = g_strdup(tmp); settings->specified_conf_file = TRUE; return on_arg; } if(strcmp(*args,"-p") == 0) { gchar tmp[16384]; args++; on_arg++; if(on_arg > total_args || sscanf(*args, "%s", tmp) != 1) { pal_output_error("%s\n", _("ERROR: *.pal file required after -p argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); return on_arg; } settings->pal_file = g_strdup(tmp); return on_arg; } if(strcmp(*args,"-u") == 0) { gchar username[256]; args++; on_arg++; if(on_arg > total_args || sscanf(*args, "%s", username) != 1) { pal_output_error("%s\n", _("ERROR: Username required after -u argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); return on_arg; } g_free(settings->conf_file); settings->conf_file = g_strconcat("/home/", username, "/.pal/pal.conf", NULL); settings->specified_conf_file = TRUE; return on_arg; } if(strcmp(*args,"-s") == 0) { args++; on_arg++; if(on_arg > total_args) { pal_output_error("%s\n", _("ERROR: Regular expression required after -s argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); } else settings->search_string = g_strdup(*args); return on_arg; } if(strcmp(*args,"-x") == 0) { args++; on_arg++; if(on_arg > total_args || sscanf(*args, "%d", &(settings->expunge)) != 1) { pal_output_error("%s\n", _("ERROR: Number required after -x argument.")); pal_output_error(" %s\n", _("Use --help for more information.")); on_arg--; } return on_arg; } pal_output_error("%s %s\n", _("ERROR: Bad argument:"), *args); pal_output_error(" %s\n", _("Use --help for more information.")); return on_arg+1; } /* used when the pal is finished running and the hashtable entries * need to be properly freed */ static void hash_table_free_item(gpointer key, gpointer value, gpointer user_data) { GList* list = (GList*) value; GList* prev = list; g_free(key); /* free the list for this hashtable key */ while(g_list_length(list) != 0) { pal_event_free((PalEvent*) list->data); list = g_list_next(list); } g_list_free(prev); } /* free the hashtable */ static void pal_main_ht_free(void) { if(ht != NULL) { g_hash_table_foreach(ht, (GHFunc) hash_table_free_item, NULL); g_hash_table_destroy(ht); ht = NULL; } } /* free, and reload the hashtable and settings from pal.conf and * calendar files */ void pal_main_reload(void) { if(settings->verbose) g_printerr("Reloading events and settings.\n"); pal_main_ht_free(); ht = load_files(); } int main(gint argc, gchar** argv) { G_CONST_RETURN gchar *charset = NULL; gint on_arg = 1; GDate* today = g_date_new(); g_date_set_time_t(today, time(NULL)); settings = g_malloc(sizeof(Settings)); settings->cal_lines = 5; settings->range_days = 0; settings->range_neg_days = 0; settings->range_arg = FALSE; settings->search_string = NULL; settings->verbose = FALSE; settings->mail = FALSE; settings->query_date = NULL; settings->expunge = -1; settings->date_fmt = g_strdup("%a %e %b %Y"); settings->week_start_monday = FALSE; settings->reverse_order = FALSE; settings->cal_on_bottom = FALSE; settings->specified_conf_file = FALSE; settings->no_columns = FALSE; settings->hide_event_type = FALSE; settings->manage_events = FALSE; settings->curses = FALSE; settings->event_color = BLUE; settings->pal_file = NULL; settings->html_out = FALSE; settings->latex_out = FALSE; settings->compact_list = FALSE; settings->term_cols = 80; settings->term_rows = 24; settings->compact_date_fmt = g_strdup("%m/%d/%Y"); settings->conf_file = g_strconcat(g_get_home_dir(), "/.pal/pal.conf", NULL); settings->show_weeknum = FALSE; g_set_print_handler( pal_output_handler ); g_set_printerr_handler( pal_output_handler ); textdomain("pal"); bind_textdomain_codeset("pal", "utf-8"); if(setlocale(LC_MESSAGES, "") == NULL || setlocale(LC_TIME, "") == NULL || setlocale(LC_ALL, "") == NULL || setlocale(LC_CTYPE, "") == NULL) pal_output_error("WARNING: Localization failed.\n"); #ifndef __CYGWIN__ /* figure out the terminal width if possible */ { struct winsize wsz; if(ioctl(0, TIOCGWINSZ, &wsz) != -1) { settings->term_cols = wsz.ws_col; settings->term_rows = wsz.ws_row; } } #endif /* parse all the arguments */ while(on_arg < argc) on_arg = parse_arg(argv,on_arg,argc); g_get_charset(&charset); if(settings->verbose) g_printerr("Character set: %s\n", charset); ht = load_files(); /* adjust settings if --mail is used */ if(settings->mail) { gchar pretty_date[128]; g_date_strftime(pretty_date, 128, settings->date_fmt, today); g_print("From: \"pal\" \n"); g_print("Content-Type: text/plain; charset=%s\n", charset); g_print("Subject: [pal] %s\n\n", pretty_date); /* let the mail reader handle the line wrapping */ settings->term_cols = -1; } if(settings->manage_events) pal_manage(); if(!settings->html_out && !settings->latex_out) { if(!settings->cal_on_bottom) { pal_output_cal(settings->cal_lines,today); /* print a newline under calendar if we're printing other stuff */ if(settings->cal_lines > 0 && (settings->range_days>0 || settings->range_neg_days>0 || settings->query_date != NULL)) g_print("\n"); } view_details(); /* prints results of -d,-r,-s */ if(settings->cal_on_bottom) { /* print a new line over calendar if we've printed other stuff */ if(settings->cal_lines > 0 && (settings->range_days>0 || settings->range_neg_days>0 || settings->query_date != NULL)) g_print("\n"); pal_output_cal(settings->cal_lines,today); } } /* end if not html_out and not latex_out */ else if(settings->html_out && settings->latex_out) { pal_output_error("ERROR: Can't use both --html and --latex.\n"); return 1; } else if(settings->html_out) pal_html_out(); else if(settings->latex_out) pal_latex_out(); g_date_free(today); pal_main_ht_free(); /* free settings */ g_free(settings->date_fmt); g_free(settings->conf_file); g_free(settings->search_string); if(settings->query_date != NULL) g_date_free(settings->query_date); g_free(settings->compact_date_fmt); g_free(settings->pal_file); g_free(settings); return 0; } pal-0.4.3/src/edit.c0000644000175000017500000001225311043370327014051 0ustar kleptogkleptog/* pal * * Copyright (C) 2004--2006, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include "main.h" #include "output.h" #include "event.h" #include "rl.h" #include "add.h" #include "del.h" #include "input.h" typedef struct _PalViewEvent { gchar *prompt; gboolean editable; gboolean changed; } PalViewEvent; PalViewEvent *fieldlist; #define NUM_FIELDS 12 static gint selectedField; static gchar align[] ="%15s "; gchar* pal_edit_get_field_val(int i, PalEvent *event, GDate *d) { gchar *buf = NULL; switch(i) { case 0: return g_strdup(event->text); case 1: return event->eventtype->get_descr( d ); case 2: buf = g_malloc(sizeof(gchar)*128); snprintf(buf, 128, "%d", event->period_count); return buf; case 3: if(event->start_date == NULL) return g_strdup(_("None")); buf = g_malloc(sizeof(gchar)*128); g_date_strftime(buf, 128, settings->date_fmt, event->start_date); return buf; case 4: if(event->end_date == NULL) return g_strdup(_("None")); buf = g_malloc(sizeof(gchar)*128); g_date_strftime(buf, 128, settings->date_fmt, event->end_date); return buf; case 5: if(event->start_time == NULL) return g_strdup(_("None")); buf = g_malloc(sizeof(gchar)*128); snprintf(buf, 128, "%02d:%02d", event->start_time->hour, event->start_time->min); return buf; case 6: if(event->end_time == NULL) return g_strdup(_("None")); buf = g_malloc(sizeof(gchar)*128); snprintf(buf, 128, "%02d:%02d", event->end_time->hour, event->end_time->min); return buf; case 7: return g_strdup(event->key); case 8: return g_strdup(event->date_string); case 9: return g_strdup(event->file_name); case 10: buf = g_malloc(sizeof(gchar)*128); snprintf(buf, 128, "%c%c", event->start, event->end); return buf; case 11: if(event->color == -1) return string_color_of(settings->event_color); return string_color_of(settings->event_color); default: return g_strdup("NOT IMPLEMENTED"); } } void pal_edit_init(void) { PalViewEvent initfieldlist[NUM_FIELDS] = { { _("Event Description"), TRUE, FALSE }, { _("Event Type"), TRUE, FALSE }, { _("Skip Count"), TRUE, FALSE }, { _("Start Date"), TRUE, FALSE }, { _("End Date"), TRUE, FALSE }, { _("Start Time"), TRUE, FALSE }, { _("End Time"), TRUE, FALSE }, { _("Hashtable Key"), FALSE, FALSE }, { _("Date in File"), FALSE, FALSE }, { _("Event File"), FALSE, FALSE }, { _("Event Marked on Calendar?"), FALSE, FALSE }, { _("File Color"), FALSE, FALSE } }; selectedField = 0; fieldlist = g_malloc(sizeof(PalViewEvent)*NUM_FIELDS); memcpy(fieldlist, initfieldlist, sizeof(PalViewEvent)*NUM_FIELDS); } void pal_edit_refresh(PalEvent* event, GDate *d) { int i; gchar *fieldval = NULL; move(0,0); for(i=0; i #include /* mkdir */ #include #include #include "main.h" #include "output.h" #include "event.h" #include "input.h" static gboolean pal_input_file_is_global(const gchar* filename); /* checks if events in the format yyyymmdd can be expunged */ static gboolean should_be_expunged(const PalEvent* pal_event) { GDate* today = NULL; GDate* event_day = NULL; if(settings->expunge < 1) return FALSE; today = g_date_new(); event_day = get_date(pal_event->date_string); g_date_set_time_t(today, time(NULL)); /* if not a yyyymmdd (ie, not recurring) */ if(event_day == NULL) { /* recurring event with end_date */ if(pal_event->end_date != NULL && g_date_days_between(today, pal_event->end_date) <= -1*settings->expunge) { g_date_free(today); return TRUE; } g_date_free(today); return FALSE; } /* if it is a yyyymmdd event (ie one-time event) */ if(g_date_days_between(today, event_day) <= -1*settings->expunge) { g_date_free(today); g_date_free(event_day); return TRUE; } g_date_free(today); g_date_free(event_day); return FALSE; } /* Returns the n'th time of the format h:mm or hh:mm that occurs in * the string s. Returns NULL if no time exists in the string */ static PalTime* pal_input_get_time(gchar* s, gint n) { gchar* s_start = s; gchar *h1, *h2, *m1, *m2; if(n < 1 || s == NULL) return NULL; while(1) { s = g_utf8_find_next_char(s, NULL); if(*s == '\0') return NULL; if(*s == ':') { /* get the digits in the hour */ h1 = g_utf8_find_prev_char(s_start, s); h2 = g_utf8_find_prev_char(s_start, h1); /* get the minutes digits */ m2 = g_utf8_find_next_char(s, NULL); if(m2 == '\0') return NULL; /* hit end of line, done */ m1 = g_utf8_find_next_char(m2, NULL); /* check for digits surrounding the : */ if(g_ascii_isdigit(*h1) && g_ascii_isdigit(*m1) && g_ascii_isdigit(*m2)) { gint hour = 0; gint min = 0; /* use 10s digit place in hours if it is a digit */ if(h2 != NULL && *h2 != '\0' && g_ascii_isdigit(*h2)) hour = 10*g_ascii_digit_value(*h2); hour += g_ascii_digit_value(*h1); min = 10*g_ascii_digit_value(*m2); min += g_ascii_digit_value(*m1); if(min >= 0 && min < 60 && hour >= 0 && hour < 24) { /* we just found a VALID date, if it is the nth * one, return it */ if(n == 1) { PalTime* time = g_malloc(sizeof(PalTime)); time->hour = hour; time->min = min; return time; } else n--; } } } } } /* reads file stream until a non-commented, non-emtpy line is * encountered */ void pal_input_skip_comments(FILE* file, FILE* out_file) { long start_of_line; gchar s[2048]; do { gchar* orig_string = NULL; start_of_line = ftell(file); if(fgets(s, 2048, file) == NULL) return; orig_string = g_strdup(s); g_strstrip(s); /* write the line out only if we aren't going to seek back later */ if(out_file != NULL && (*s == '#' || *s=='\0')) fputs(orig_string, out_file); g_free(orig_string); } while(*s == '#' || *s == '\0'); /* now we are on the next non-comment, non-emtpy line. */ /* jump back in stream so the next line read is not a comment */ fseek(file, start_of_line, SEEK_SET); } /* reads in the 'first' line of the .pal file (two marker characters * and calendar title) */ PalEvent* pal_input_read_head(FILE* file, FILE* out_file, gchar* filename) { gchar s[2048]; gchar c; PalEvent* event_head = NULL; if(fgets(s, 2048, file) == NULL) { pal_output_error(_("WARNING: File is missing 2 character marker and event type: %s\n"), filename); return NULL; } if(out_file != NULL) fputs(s, out_file); event_head = pal_event_init(); g_strstrip(s); event_head->start = g_utf8_get_char(s); event_head->end = g_utf8_get_char(g_utf8_offset_to_pointer(s,1)); c = g_utf8_get_char(g_utf8_offset_to_pointer(s,2)); event_head->type = g_strdup(g_utf8_offset_to_pointer(s,3)); event_head->file_name = g_strdup(filename); event_head->global = pal_input_file_is_global(filename); if(c != ' ' && c != '\t') /* there should be white space here */ { gchar* file = g_path_get_basename(filename); pal_output_error(_("ERROR: First line is improperly formatted.\n")); pal_output_error( " %s: %s\n", _("FILE"), file); g_free(file); pal_output_error( " %s: %s\n", _("LINE"), s); pal_event_free(event_head); return NULL; } /* check if text if UTF-8 */ if(!g_utf8_validate(event_head->type, -1, NULL)) pal_output_error(_("ERROR: First line is not ASCII or UTF-8 in %s.\n"), filename); g_strstrip(event_head->type); return event_head; } gboolean pal_input_eof(FILE* file) { if(feof(file) != 0) return TRUE; return FALSE; } /* Returns: The PalEvent for the next event in the file (or del_event if del_event was deleted). * file: File stream to read from. * out_file: Print the expunged output to out_file if it isn't NULL * filename: Name of the file corresponding to the "file" stream * event_head: Default to these values for the returned PalEvent. * del_event: If this event is encountered in the file, do not print it to out_file */ PalEvent* pal_input_read_event(FILE* file, FILE* out_file, gchar* filename, PalEvent* event_head, PalEvent* del_event) { gchar s[2048]; gchar date_string[128]; gchar* text_string = NULL; gchar* tmp = NULL; PalEvent* pal_event = NULL; if(fgets(s, 2048, file) == NULL) return NULL; /* first word is the date string */ sscanf(s, "%s", date_string); /* the rest is the descriptive text */ text_string = g_strdup(s+strlen(date_string)); /* a roundabout way of making date_string uppercase. The keys in hashtable must be uppercase, but pal's .pal files are case insensitive. */ g_strstrip(date_string); tmp = g_ascii_strup(date_string, -1); sscanf(tmp, "%s", date_string); g_free(tmp); g_strstrip(text_string); pal_event = pal_event_copy(event_head); /* check for a valid date_string */ if(!parse_event( pal_event, date_string )) { gchar* file = g_path_get_basename(filename); pal_output_error(_("ERROR: Invalid date string.\n")); pal_output_error( " %s: %s\n", _("FILE"), file); pal_output_error( " %s: %s\n", _("LINE"), s); g_free(file); /* copy bad line */ if(out_file != NULL) fputs(s, out_file); g_free(text_string); pal_event_free( pal_event ); return NULL; } /* require a description for a event */ if(strlen(text_string) == 0) { gchar* file = g_path_get_basename(filename); pal_output_error(_("ERROR: Event description missing.\n")); pal_output_error( " %s: %s\n", _("FILE"), file); pal_output_error( " %s: %s\n", _("LINE"), s); g_free(file); /* copy bad line */ if(out_file != NULL) fputs(s, out_file); g_free(text_string); pal_event_free( pal_event ); return NULL; } /* check if text if UTF-8 */ if(!g_utf8_validate(text_string, -1, NULL)) pal_output_error(_("ERROR: Event text '%s' is not ASCII or UTF-8 in file %s.\n"), text_string, filename); /* Sanity checks */ if( pal_event->period_count != 1 && !pal_event->start_date ) { gchar* file = g_path_get_basename(filename); pal_event->start_date = g_date_new(); g_date_set_time_t(pal_event->start_date, time(NULL)); pal_event->end_date = g_date_new_dmy(1,1,3000); pal_output_error(_("ERROR: Event with count has no start date\n")); pal_output_error( " %s: %s\n", _("FILE"), file); pal_output_error( " %s: %s\n", _("LINE"), s); } pal_event->text = g_strdup(text_string); pal_event->start_time = pal_input_get_time(text_string, 1); pal_event->end_time = pal_input_get_time(text_string, 2); pal_event->date_string = g_strdup(date_string); if(out_file != NULL) { /* don't print to out_file if event should be expunged */ if(should_be_expunged(pal_event)) { if(settings->verbose) g_printerr("%s: %s", _("Expunged"), s); pal_event_free(pal_event); g_free(text_string); return NULL; } /* don't print to out_file if event should be deleted */ else if(del_event != NULL && strcmp(pal_event->date_string, del_event->date_string) == 0 && strcmp(pal_event->text, del_event->text) == 0) { pal_event_free(pal_event); g_free(text_string); return del_event; } else /* otherwise, print to out_file */ fputs(s, out_file); } g_free(text_string); return pal_event; } /* checks if file is a global */ static gboolean pal_input_file_is_global(const gchar* filename) { if(strncmp(filename, PREFIX "/share/pal", strlen(PREFIX "/share/pal")) == 0) return TRUE; return FALSE; } /* loads a pal calendar file, returns the number of events loaded into hashtable */ static gint load_file(gchar* filename, FILE* file, gint filecount, gboolean hide, int color) { gint eventcount = 0; PalEvent* event_head; FILE *out_file = NULL; gchar* out_filename = NULL; g_strstrip(filename); out_filename = g_strconcat(filename, ".paltmp", NULL); /* if -x is used and the file isn't a global calendar, expunge */ if(settings->expunge > 0 && !pal_input_file_is_global(out_filename)) { out_file = fopen(out_filename, "w"); if(out_file == NULL) { pal_output_error(_("ERROR: Can't write file: %s\n"), out_filename); pal_output_error( " %s\n", _("File will not be expunged: %s"), filename); } } pal_input_skip_comments(file, out_file); event_head = pal_input_read_head(file, out_file, filename); if(event_head != NULL) { event_head->color = color; event_head->file_num = filecount; event_head->hide = hide; while(1) { GList* days_events = NULL; PalEvent* pal_event = NULL; pal_input_skip_comments(file, out_file); pal_event = pal_input_read_event(file, out_file, filename, event_head, NULL); if(pal_event == NULL && pal_input_eof(file)) break; if(pal_event != NULL) { gchar* key = pal_event->key; eventcount++; /* if no list exists for that key, make new list */ if(g_hash_table_lookup(ht, key) == NULL) { days_events = NULL; days_events = g_list_append(days_events, pal_event); g_hash_table_insert(ht,g_strdup(key),days_events); } else /* else, append to current list */ { days_events = g_hash_table_lookup(ht,key); days_events = g_list_append(days_events,pal_event); } } } } if(out_file != NULL) { fclose(out_file); if(rename(out_filename, filename) != 0) pal_output_error(_("ERROR: Can't rename %s to %s\n"), out_filename, filename); } g_free( out_filename ); pal_event_free(event_head); return eventcount; } /* gets the pal file to load. From "file", it looks for a pal * calendar file locally or globally to load and puts the path of that * file in pal_file. It returns true if successful. */ static gboolean get_file_to_load(gchar* file, gchar* pal_file, gboolean show_error) { if(g_path_is_absolute(file)) { if(! g_file_test(file, G_FILE_TEST_EXISTS) || g_file_test(file, G_FILE_TEST_IS_DIR)) { if(show_error) pal_output_error(_("ERROR: File doesn't exist: %s\n"), file); return FALSE; } else sprintf(pal_file, file); } else { /* if a relative path, try looking in the path found in settings->conf_file */ gchar* dirname = g_path_get_dirname(settings->conf_file); sprintf(pal_file, "%s/%s", dirname, file); /* if that doesn't work, try looking in PREFIX/share/pal */ if(! g_file_test(pal_file, G_FILE_TEST_EXISTS) || g_file_test(pal_file, G_FILE_TEST_IS_DIR)) sprintf(pal_file, PREFIX "/share/pal/%s", file); /* if that doesn't work, print message */ if(! g_file_test(pal_file, G_FILE_TEST_EXISTS) || g_file_test(pal_file, G_FILE_TEST_IS_DIR)) { gchar other_file[2048]; sprintf(other_file, "%s/%s", dirname, file); if(show_error) { pal_output_error(_("ERROR: Can't find file. I tried %s and %s.\n"), other_file, pal_file); exit(1); /* if we don't exit, this error gets buried * when -m is used. */ } g_free(dirname); return FALSE; } g_free(dirname); } return TRUE; } /* opens a file for reading. Prints error if can't read file. * Returns NULL if can't read, returns a FILE pointer if reading file. * fclose() should be called on the returned pointer when done reading * the file. */ static FILE* get_file_handle(gchar* filename, gboolean show_error) { FILE* file = fopen(filename, "r"); if(settings->verbose) g_printerr(_("Reading: %s\n"), filename); if(file == NULL && show_error) pal_output_error(_("ERROR: Can't read file: %s\n"), filename); return file; } /* loads calendar files and settings from a pal.conf file */ GHashTable* load_files() { gchar s[2048]; gchar text[2048]; FILE* file = NULL; guint filecount=0, eventcount=0; ht = g_hash_table_new(g_str_hash,g_str_equal); if(settings->verbose) { if(settings->expunge >= 0) g_printerr(_("Looking for data to expunge.\n")); } file = get_file_handle(settings->conf_file, FALSE); if(file == NULL) { if(settings->specified_conf_file) { pal_output_error(_("ERROR: Can't open file: %s\n"), settings->conf_file); return ht; } else /* didn't specify conf file, and couldn't find conf file: create a default one */ { FILE* out_file; gchar* out_dirname; gchar* out_path; gint c; out_dirname = g_strconcat(g_get_home_dir(), "/.pal", NULL); out_path = g_strconcat(out_dirname, "/pal.conf", NULL); pal_output_error(_("NOTE: Creating %s\n"), out_path); pal_output_error(_("NOTE: Edit ~/.pal/pal.conf to change how and if certain events are displayed.\n"), out_path); /* create directory if it doesn't exist */ if(!g_file_test(out_dirname, G_FILE_TEST_IS_DIR)) { if(mkdir(out_dirname, 0755) != 0) { pal_output_error(_("ERROR: Can't create directory: %s\n"), out_dirname); return ht; } } /* attempt to copy /etc/pal.conf to ~/.pal/pal.conf */ file = fopen("/etc/pal.conf", "r"); /* if not found, try PREFIX/share/pal/pal.conf instead */ /* NOTE: This is will be removed in the future */ if(file == NULL) file = fopen(PREFIX "/share/pal/pal.conf", "r"); if(file == NULL) { pal_output_error(_("ERROR: Can't open file: /etc/pal.conf\n")); pal_output_error(_("ERROR: Can't open file: " PREFIX "/share/pal/pal.conf\n")); pal_output_error(_("ERROR: This indicates an improper installation.\n")); return ht; } out_file = fopen(out_path, "w"); if(out_file == NULL) { pal_output_error(_("ERROR: Can't create/write file: %s\n"), out_file); return ht; } /* do copy */ c = fgetc(file); while(c != EOF) { fputc(c,out_file); c=fgetc(file); } fclose(out_file); fclose(file); g_free(out_dirname); g_free(out_path); /* open file to read it as usual */ file = fopen(settings->conf_file, "r"); } } /* done opening/creating file */ /* if using -p, load that .pal file now. */ if(settings->pal_file != NULL) { gchar pal_file[16384]; FILE* pal_file_handle = NULL; if(!get_file_to_load(settings->pal_file, pal_file, FALSE)) sprintf(pal_file, settings->pal_file); pal_file_handle = get_file_handle(pal_file, TRUE); if(pal_file_handle != NULL) { eventcount += load_file(pal_file, pal_file_handle, filecount, FALSE, -1); fclose(pal_file_handle); filecount++; } } while(fgets(s, 2048, file) != NULL) { gchar pal_file[16384]; gchar color[16384]; gint int_color = -1; gint i,j; color[0] = '\0'; g_strstrip(s); if(sscanf(s, "file %s (%[a-z])\n", text, color) == 2 || sscanf(s, "file %s\n", text) == 1) { FILE* pal_file_handle = NULL; gboolean hide = FALSE; /* skip this line if we're using -p */ if(settings->pal_file != NULL) continue; if(sscanf(s, "file_hide %s (%[a-z])\n", text, color) == 2) hide = TRUE; else if(sscanf(s, "file_hide %s\n", text) == 1) hide = TRUE; if(color[0] != '\0') { if(int_color_of(color) != -1) int_color = int_color_of(color); if(int_color == -1) { pal_output_error(_("ERROR: Invalid color '%s' in file %s."), color, settings->conf_file); pal_output_error("\n %s %s\n", _("Valid colors:"), "black, red, green, yellow, blue, magenta, cyan, white"); } } if(get_file_to_load(text, pal_file, TRUE)) { pal_file_handle = get_file_handle(pal_file, TRUE); if(pal_file_handle != NULL) { /* assign events that are the "default" color to * have a color of -1 the output code will apply * the default color to events (since we might not * have read in what the default color is yet. */ eventcount += load_file(pal_file, pal_file_handle, filecount, hide, int_color); fclose(pal_file_handle); filecount++; } } } else if(sscanf(s, "date_fmt %s",text) == 1) { g_free(settings->date_fmt); settings->date_fmt = g_strdup(g_strstrip(&s[9])); } else if(strcmp(s, "week_start_monday") == 0) settings->week_start_monday = TRUE; else if(strcmp(s, "show_weeknum") == 0) settings->show_weeknum = TRUE; else if(strcmp(s, "reverse_order") == 0) settings->reverse_order = TRUE; else if(strcmp(s, "cal_on_bottom") == 0) settings->cal_on_bottom = TRUE; else if(strcmp(s, "no_columns") == 0) settings->no_columns = TRUE; else if(strcmp(s, "hide_event_type") == 0) settings->hide_event_type = TRUE; else if(strcmp(s, "compact_list") == 0) settings->compact_list = TRUE; else if(sscanf(s, "compact_date_fmt %s",text) == 1) { g_free(settings->compact_date_fmt); settings->compact_date_fmt = g_strdup(g_strstrip(&s[17])); } else if(sscanf(s, "event_color %s",text) == 1) { int ec = int_color_of(text); if(ec == -1) { pal_output_error("%s\n", _("ERROR: Invalid color '%s' in file %s."), color, settings->conf_file); pal_output_error(" %s %s\n", _("Valid colors:"), "black, red, green, yellow, blue, magenta, cyan, white"); } else settings->event_color = ec; } else if(sscanf(s, "default_range %d-%d", &i, &j) == 2) { /* check if -r was used */ if(!settings->range_arg) { settings->range_neg_days = i; settings->range_days = j; } } else if(sscanf(s, "default_range %d", &i) == 1) { if(!settings->range_arg) settings->range_days = i; } /* ignore empty lines or comments */ else if(*s != '#' && *s != '\0') { pal_output_error(_("ERROR: Invalid line (File: %s, Line text: %s)\n"), settings->conf_file, s); } } fclose(file); if(settings->verbose) g_printerr(_("Done reading data (%d events, %d files).\n\n"), eventcount, filecount); return ht; } pal-0.4.3/src/search.c0000644000175000017500000001544411043370327014376 0ustar kleptogkleptog/* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include /* FreeBSD, regex.h needs this */ #include /* regular expressions */ #include "main.h" #include "output.h" #include "event.h" #include "search.h" /* returns a list of the events matching the 'search' string. 'date' * is the starting date. 'window' is the number of days from the * starting date to search. * * The returned list alternates between GDate and PalEvent pointers. * The GDate pointer allows the caller to determine the date the event * was found on (because the event could be recurring and happen * multiple times). The GDate pointers in the list should be freed. * The PalEvent pointers should not be freed. */ static GList* pal_search_get_results(const gchar* search, const GDate* date, const gint window) { regex_t preg; gint i,j; GList* hit_list = NULL; GDate *searchdate = g_date_new(); memcpy( searchdate, date, sizeof( GDate ) ); if(settings->reverse_order) g_date_add_days(searchdate, window-1); regcomp(&preg, search, REG_ICASE|REG_NOSUB); for(i=0; idata))->text, 0, NULL, 0)==0 || regexec(&preg, ((PalEvent*) (item->data))->type, 0, NULL, 0)==0) { GDate* tmp = g_malloc(sizeof(GDate)); memcpy(tmp, searchdate, sizeof(GDate)); hit_list = g_list_append(hit_list, tmp); hit_list = g_list_append(hit_list, item->data); } item = g_list_next(item); } } if(settings->reverse_order) g_date_subtract_days(searchdate, 1); else g_date_add_days(searchdate, 1); } regfree(&preg); return hit_list; } /* returns the number of events found */ int pal_search_view(const gchar* search_string, GDate* date, const gint window, const gboolean number_events) { GList* hit_list = pal_search_get_results(search_string, date, window); GList* item = NULL; int hit_count = g_list_length(hit_list) / 2; int event_count = 1; gchar start_date[128]; gchar end_date[128]; g_date_strftime(start_date, 128, settings->date_fmt, date); g_date_add_days(date, window-1); g_date_strftime(end_date, 128, settings->date_fmt, date); g_date_subtract_days(date, window-1); pal_output_attr(BRIGHT, _("[ Begin search results: %s ]\n[ From %s to %s inclusive ]\n\n"), search_string, start_date, end_date); item = g_list_first(hit_list); while(g_list_length(item) != 0) { PalEvent* event_tmp = NULL; GDate* date_tmp = NULL; GDate* next_date = NULL; date_tmp = (GDate*) (item->data); item = g_list_next(item); event_tmp = (PalEvent*) (item->data); item = g_list_next(item); if(!settings->compact_list) pal_output_date_line(date_tmp); if(number_events) pal_output_event(event_tmp, date_tmp, event_count++); else pal_output_event(event_tmp, date_tmp, -1); if(g_list_length(item) != 0) next_date = (GDate*) item->data; while(g_list_length(item) != 0 && g_date_compare(next_date, date_tmp) == 0) { g_date_free(date_tmp); date_tmp = (GDate*) (item->data); item = g_list_next(item); event_tmp = (PalEvent*) (item->data); item = g_list_next(item); if(number_events) pal_output_event(event_tmp, date_tmp, event_count++); else pal_output_event(event_tmp, date_tmp, -1); if(g_list_length(item) != 0) next_date = (GDate*) item->data; } g_date_free(date_tmp); if(!settings->compact_list) g_print("\n"); } g_list_free(hit_list); /* no extra newlines when using compact list, so add one here */ if(settings->compact_list) g_print("\n"); pal_output_attr(BRIGHT, _("[ End search results: %s ]"), search_string); pal_output_attr(BRIGHT, ngettext("[ %d event found ]\n", "[ %d events found ]\n", hit_count), hit_count); return hit_count; } /* Returns the event 'event_number' from the search. Stores the date * the event occurs on in store_date */ PalEvent* pal_search_event_num(gint event_number, GDate** store_date, const gchar* search_string, const GDate* date, const gint window) { PalEvent* ret_val = NULL; GList* hit_list = pal_search_get_results(search_string, date, window); gint num_events = g_list_length(hit_list) / 2; GList* tmp = NULL; if(hit_list == NULL || event_number < 1 || event_number > num_events) return NULL; *store_date = (GDate*) g_list_nth_data(hit_list, (event_number-1)*2); ret_val = (PalEvent*) g_list_nth_data(hit_list, (event_number-1)*2+1); tmp = g_list_first(hit_list); while(tmp != NULL) { if(*store_date != (GDate*) (tmp->data)) g_date_free((GDate*) (tmp->data)); tmp = g_list_next(tmp); tmp = g_list_next(tmp); } g_list_free(hit_list); return ret_val; } /* A simpler search, just searches for the first event which contains this * string. Used by the interactive search in the manage interface. Attempts * a semblance of case-insensetivity */ gboolean pal_search_isearch_event( GDate **date, gint *selected, gchar *string, gboolean forward) { int i, j; gboolean found = FALSE; gchar *searchstring = g_utf8_casefold(string,-1); /* Search upto a year */ for(i=0; i<366; i++) { GList* events = get_events(*date); if(events != NULL) { GList* item = g_list_first(events); for(j=0; jdata))->type, ": ", ((PalEvent*) (item->data))->text, NULL ); gchar *string2 = g_utf8_casefold(string,-1); if( strstr( string2, searchstring ) ) { *selected = j; found = TRUE; } g_free(string); g_free(string2); item = g_list_next(item); } g_list_free( events ); } if( found ) break; if(forward) g_date_add_days(*date, 1); else g_date_subtract_days(*date, 1); } g_free(searchstring); return found; } pal-0.4.3/src/search.h0000644000175000017500000000221611043370327014374 0ustar kleptogkleptog#ifndef PAL_SEARCH_H #define PAL_SEARCH_H /* pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ PalEvent* pal_search_event_num(gint event_number, GDate** store_date, const gchar* search_string, const GDate* date, const gint window); int pal_search_view(const gchar* search_string, GDate* date, const gint window, const gboolean number_events); gboolean pal_search_isearch_event( GDate **date, gint *selected, gchar *string, gboolean forward); #endif pal-0.4.3/src/Makefile0000644000175000017500000002044511043370327014422 0ustar kleptogkleptogNAME = pal include Makefile.defs INCLDIR = -I${prefix}/include `pkg-config --cflags glib-2.0` LIBDIR = LIBS = `pkg-config --libs glib-2.0` -lreadline -lncurses SRC = main.c colorize.c output.c input.c event.c rl.c html.c latex.c \ add.c edit.c del.c remind.c search.c manage.c OBJ = $(SRC:.c=.o) ifeq ($(DEBUG),1) TMPDIR = tmp.debug else TMPDIR = tmp.opt endif OBJ = $(addprefix $(TMPDIR)/,$(SRC:.c=.o)) $(NAME): info $(OBJ) @echo " [gcc] $(NAME)" @$(CC) $(CFLAGS) $(OBJ) $(LDFLAGS) -o $(NAME) ifneq ($(DEBUG),1) @echo " [strip] $(NAME)" @strip $(NAME) endif info: @echo "Using CFLAGS: $(CFLAGS)" @echo "Using CPPFLAGS: $(CPPFLAGS)" @echo "Using LDFLAGS: $(LDFLAGS)" # make dependency files tmp.deps/%.d: %.c @echo " [deps] $(@)" @mkdir -p tmp.deps @set -e; $(CC) -MM $(CFLAGS) $(CPPFLAGS) $< \ | sed 's/\($*\)\.o[ :]*/tmp.opt\/\1.o $* : /g' > $@; \ [ -s $@ ] || rm -f $@ @set -e; $(CC) -MM $(CFLAGS) $(CPPFLAGS) $< \ | sed 's/\($*\)\.o[ :]*/tmp.debug\/\1.o $* : /g' >> $@; \ [ -s $@ ] || rm -f $@ # Include dependency files here. # If the files don't exist, this will fail silently and remake the dep files. -include $(addprefix tmp.deps/,$(SRC:.c=.d)) tmp.debug/%.o: Makefile Makefile.defs @mkdir -p tmp.debug @echo " [${CC} debug] $*.c" @$(CC) $(CFLAGS) $(CPPFLAGS) -c $*.c $(OUTPUT_OPTION) tmp.opt/%.o: Makefile Makefile.defs @mkdir -p tmp.opt @echo " [${CC}] $*.c" @$(CC) $(CFLAGS) $(CPPFLAGS) -c $*.c $(OUTPUT_OPTION) debug: clean @$(MAKE) DEBUG=1 # Use "install-no-rm" instead of "install" if you don't want to check # for old files that should be removed before installing the new # version. This is useful for automated package managers that # automatically remove files when a program is uninstalled (ie # portage, rpm). install-no-rm: install-mo install-man install-doc install-bin install-share # Install binary file install-bin: @echo " --- Installing binary --- " @mkdir -p ${DESTDIR}${prefix}/bin; install -m 0755 -o root pal ${DESTDIR}${prefix}/bin; install -m 0755 -o root convert/vcard2pal ${DESTDIR}${prefix}/bin; @echo install-share: @echo " --- Installing global data --- " @mkdir -p ${DESTDIR}${prefix}/share/pal; install -m 0644 -o root ../share/*.pal ${DESTDIR}${prefix}/share/pal @mkdir -p ${DESTDIR}/etc; install -m 0644 -o root ../pal.conf ${DESTDIR}/etc/ @echo # "install" will install the files needed by pal and also check to see # if there are old pal files that should be removed. If you don't # want the install process to attempt to remove old files, use # "install-no-rm". install: install-no-rm @echo " --- Checking for files to remove --- " @echo " NOTE: You might be prompted to remove some files that appear" @echo " to be from an old pal installation. Unless you know that" @echo " that you need these files, you should probably delete them" @echo " by always answering 'y'." @# prompt about removing old doc directories @find ${prefix}/share/doc -name pal-[0-9].[0-9].[0-9]\* -a \! -name pal-$(PAL_VERSION) -a -type d -maxdepth 1 -exec rm -ri {} \;; @# Remove pal.conf from its old location @rm -f ${prefix}/share/pal/pal.conf; @echo # Install man page install-man: @echo " --- Installing man page --- " cd ../; sed 's/PAL_VERSION/$(PAL_VERSION)/' pal.1.template | gzip -9 > pal.1.gz @mkdir -p ${DESTDIR}${prefix}/share/man/man1/ install -m 0644 -o root ../pal.1.gz ${DESTDIR}${prefix}/share/man/man1/ install -m 0644 -o root convert/vcard2pal.1 ${DESTDIR}${prefix}/share/man/man1/ rm ../pal.1.gz @echo # Install documentation install-doc: @echo " --- Installing docs --- " @mkdir -p ${DESTDIR}${prefix}/share/doc/pal-$(PAL_VERSION); cat ../COPYING | gzip -9 > ../COPYING.gz install -m 0644 -o root ../COPYING.gz ${DESTDIR}${prefix}/share/doc/pal-$(PAL_VERSION); rm ../COPYING.gz cat ../INSTALL | gzip -9 > ../INSTALL.gz install -m 0644 -o root ../INSTALL.gz ${DESTDIR}${prefix}/share/doc/pal-$(PAL_VERSION); rm ../INSTALL.gz cat ../ChangeLog | gzip -9 > ../ChangeLog.gz install -m 0644 -o root ../ChangeLog.gz ${DESTDIR}${prefix}/share/doc/pal-$(PAL_VERSION); rm ../ChangeLog.gz install -m 0644 -o root ../doc/example.css ${DESTDIR}${prefix}/share/doc/pal-$(PAL_VERSION); @echo # install locale information install-mo: @echo " --- Installing locale information --- " @# GERMAN mkdir -p ${DESTDIR}${prefix}/share/locale/de/LC_MESSAGES/ cd ../po; msgfmt de.po -o de.mo install -m 0644 -o root ../po/de.mo ${DESTDIR}${prefix}/share/locale/de/LC_MESSAGES/pal.mo rm ../po/de.mo @# SWEDISH mkdir -p ${DESTDIR}${prefix}/share/locale/sv/LC_MESSAGES/ cd ../po; msgfmt sv.po -o sv.mo install -m 0644 -o root ../po/sv.mo ${DESTDIR}${prefix}/share/locale/sv/LC_MESSAGES/pal.mo rm ../po/sv.mo @# SPANISH mkdir -p ${DESTDIR}${prefix}/share/locale/es/LC_MESSAGES/ cd ../po; msgfmt es.po -o es.mo install -m 0644 -o root ../po/es.mo ${DESTDIR}${prefix}/share/locale/es/LC_MESSAGES/pal.mo rm ../po/es.mo @# POLISH mkdir -p ${DESTDIR}${prefix}/share/locale/pl/LC_MESSAGES/ cd ../po; msgfmt pl.po -o pl.mo install -m 0644 -o root ../po/pl.mo ${DESTDIR}${prefix}/share/locale/pl/LC_MESSAGES/pal.mo rm ../po/pl.mo @# TURKISH mkdir -p ${DESTDIR}${prefix}/share/locale/tr/LC_MESSAGES/ cd ../po; msgfmt tr.po -o tr.mo install -m 0644 -o root ../po/tr.mo ${DESTDIR}${prefix}/share/locale/tr/LC_MESSAGES/pal.mo rm ../po/tr.mo @echo # try to uninstall pal uninstall: uninstall-mo uninstall-man @echo " --- Removing binary --- " rm -f ${prefix}/bin/pal; @echo @echo " --- Removing global data --- " rm -rf ${prefix}/share/pal; @echo @echo " --- Removing doc directory --- " rm -rf ${prefix}/share/doc/pal-$(PAL_VERSION); @echo @echo " --- Removing /etc/pal.conf --- " rm -f /etc/pal.conf; @echo @echo " --- Check for doc directories for other versions of pal --- " @echo " NOTE: If you don't have other copies of pal installed, you can" @echo " safely delete the directories listed below:" @find ${prefix}/share/doc -name pal-[0-9].[0-9].[0-9]\* -type d -maxdepth 1; # uninstall locale information uninstall-mo: @echo " --- Removing locale info --- " cd ${prefix}/share/locale/; find -name pal.mo -exec rm {} \;; @echo # uninstall man page uninstall-man: @echo " --- Removing man page --- " rm -f ${prefix}/share/man/man1/pal.1.gz @echo # Generates a new pot file from the .c files pot: $(SRC) @echo Generating new pot file from .c files. @xgettext -k_ --copyright-holder="Scott Kuhl" $(SRC) -o ../po/pal.pot @sed 's/\(#.*\)\YEAR/\12005/' ../po/pal.pot | \ sed 's/\(#.*\)\SOME DESCRIPTIVE TITLE\./\1pal calendar/' | \ sed 's/\(#.*\)\FIRST AUTHOR /\1Scott Kuhl/' | \ sed 's/\("Project-Id-Version: \)PACKAGE VERSION\(\\n"\)/\1pal $(PAL_VERSION)\2/' | \ sed 's/\(#.*\)\PACKAGE/\1pal/' > ../po/pal.pot.tmp @mv ../po/pal.pot.tmp ../po/pal.pot # Remove binay, object files and emacs backup files clean: rm -rf $(NAME) libpal.a tmp.opt tmp.debug *.o *~ # Remove object files and dependency files cleandeps: clean rm -rf tmp.deps *.d cleandep: cleandeps distclean: cleandeps clobber: cleandeps splint: splint $(INCLDIR) $(SRC) # this rule creates a tgz with all of the needed source files for # distribution dist: pot @echo rm -rf ../pal-$(PAL_VERSION) mkdir ../pal-$(PAL_VERSION) mkdir ../pal-$(PAL_VERSION)/src mkdir ../pal-$(PAL_VERSION)/src/convert mkdir ../pal-$(PAL_VERSION)/share mkdir ../pal-$(PAL_VERSION)/doc mkdir ../pal-$(PAL_VERSION)/po cd ../; \ cp Makefile ChangeLog INSTALL COPYING pal.spec.template pal.1.template pal.conf pal-$(PAL_VERSION); \ sed 's/Version:.*/Version: $(PAL_VERSION)/' pal.spec.template > pal-$(PAL_VERSION)/pal-$(PAL_VERSION).spec; \ cp src/*.[ch] src/Makefile src/Makefile.defs pal-$(PAL_VERSION)/src; \ cp src/convert/*.[ch] src/convert/vcard2pal{,.1} src/convert/Makefile pal-$(PAL_VERSION)/src/convert; \ cp doc/example.css pal-$(PAL_VERSION)/doc; \ cp share/*.pal pal-$(PAL_VERSION)/share; \ cp po/*.po po/pal.pot po/README pal-$(PAL_VERSION)/po; @echo @echo " --- CREATING tgz file with the files listed below ---" cd ../; tar -czvf pal-$(PAL_VERSION).tgz pal-$(PAL_VERSION) @echo " --- DONE! (created pal-$(PAL_VERSION).tgz in parent directory) --- " rm -rf ../pal-$(PAL_VERSION) srpm: dist rpmbuild -ts ../pal-$(PAL_VERSION).tgz libpal.a: $(OBJ) rm -f libpal.a ar rcv libpal.a $(OBJ) strip --strip-symbol=main libpal.a ar s libpal.a ranlib libpal.a pal-0.4.3/src/convert/0000755000175000017500000000000011043370327014435 5ustar kleptogkleptogpal-0.4.3/src/convert/pal2ical.c0000644000175000017500000001071611043370327016275 0ustar kleptogkleptog/* pal2ical * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include "../main.h" #include "../input.h" #include "../event.h" #include #include #include #include int ical_uid = 0; /* timezone information */ extern char *tzname[2]; void begin_vevent(PalEvent* event) { g_print("BEGIN:VEVENT\n"); g_print("UID:%d\n", ical_uid++); g_print("SUMMARY:%s\n", event->text); } void end_vevent() { g_print("END:VEVENT\n"); } void print_dtstartend(gchar* start_date, PalTime* start_time, PalTime* end_time) { /* if start time is NULL, end_time must be NULL too */ if(start_time == NULL) { int date_int; g_print("DTSTART;VALUE=DATE:%s\n", start_date); /* assume the event is an all day event since there are no times for it */ GDate* d = get_date(start_date); g_date_add_days(d, 1); g_print("DTEND;VALUE=DATE:%s\n", get_key(d)); } else { g_print("DTSTART;TZID=%s:%sT%02d%02d00\n", tzname[0], start_date, start_time->hour, start_time->min); g_print("DTEND;TZID=%s:%sT", tzname[0], start_date); if(end_time == NULL) g_print("%02d%02d00\n", start_time->hour, start_time->min); else g_print("%02d%02d00\n", end_time->hour, end_time->min); } } void print_vtodo(PalEvent *event) { g_print("BEGIN:VTODO\n"); g_print("UID:%d\n", ical_uid++); g_print("SUMMARY:%s\n", event->text); g_print("END:VTODO\n"); } int main(int argc, char* argv[]) { char* line; FILE* stream; int error_count = 0; if(argc == 1) { g_printerr("pal2ical %s - Copyright (C) 2004, Scott Kuhl\n", PAL_VERSION); g_printerr(" %s", "pal is licensed under the GNU General Public License and has NO WARRANTY.\n\n"); g_printerr("Usage: pal2ical pal-file.pal > ical-file.ics\n"); g_printerr("\n"); exit(1); } stream = fopen(argv[1],"r"); if(stream == 0) { g_printerr("Can't read input file.\n"); exit(1); } /* initialize the timezone information (tzname external variable) */ tzset(); pal_input_skip_comments(stream, NULL); PalEvent* head = pal_input_read_head(stream, NULL, argv[1]); pal_input_skip_comments(stream, NULL); g_print("BEGIN:VCALENDAR\n"); g_print("VERSION: 2.0\n"); g_print("CALSCALE:GREGORIAN\n"); g_print("PRODID:-//pal calendar/pal2ical %s//EN\n", PAL_VERSION); g_print("X-WR-CALNAME;VALUE=TEXT:%s\n", head->type); PalEvent* empty_event = pal_event_init(); PalEvent* event = pal_input_read_event(stream, NULL, argv[1], empty_event, NULL); while(event != NULL) { /* convert one-time events of format yyyymmdd */ if(is_valid_yyyymmdd(event->date_string, 0)) { begin_vevent(event); print_dtstartend(event->date_string, event->start_time, event->end_time); end_vevent(); } else if(is_valid_0000mmdd(event->date_string)) { begin_vevent(event); if(event->start_date != NULL) print_dtstartend(event->start_date, event->start_time, event->end_time); else print_dtstartend(g_strconcat("1700", event->date_string+4, NULL), event->start_time, event->end_time); if(event->end_date != NULL) g_print("RRULE:FREQ=YEARLY;UNTIL=%s\n", get_key(event->end_date)); else g_print("RRULE:FREQ=YEARLY\n"); end_vevent(); } /* TODO event */ else if(event->is_todo) { print_vtodo(event); } else { /* ADD MORE STUFF HERE */ g_printerr("Can't convert this type event yet: %s %s\n", event->date_string, event->text); error_count++; } event = pal_input_read_event(stream, NULL, argv[1], empty_event, NULL); pal_input_skip_comments(stream, NULL); } g_print("END:VCALENDAR\n"); g_printerr("DONE!\n\n"); g_printerr("Events converted: %d\n", ical_uid); g_printerr("Events that could not be converted: %d\n", error_count); return 0; } pal-0.4.3/src/convert/ical2pal.c0000644000175000017500000002244311043370327016275 0ustar kleptogkleptog/* ical2pal * * Copyright (C) 2004, Scott Kuhl * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #include #include #include #include "ical.h" #include char* read_stream(char *s, size_t size, void *d) { char *c = fgets(s,size, (FILE*)d); return c; } void output_pal_from_ical(icalcomponent* c) { int good_event = 0; int bad_event = 0; int error_flag = 0; icalcomponent* vevent = icalcomponent_get_first_component(c, ICAL_VEVENT_COMPONENT); while(vevent != 0) { icalproperty* rrule; struct icalrecurrencetype recur; icalproperty* summary = icalcomponent_get_first_property(vevent, ICAL_SUMMARY_PROPERTY); struct icaltimetype start_value = icalcomponent_get_dtstart(vevent); struct icaltimetype end_value = icalcomponent_get_dtend(vevent); struct icaldurationtype duration = icaltime_subtract(end_value, start_value); char startstop[19]; char time[15]; const char* summary_text = NULL; startstop[0] = '\0'; time[0] = '\0'; if(duration.days > 1 || duration.weeks > 1) snprintf(startstop, 19, ":%04i%02i%02i:%04i%02i%02i", start_value.year, start_value.month, start_value.day, end_value.year, end_value.month, end_value.day); if(duration.minutes > 0 || duration.hours > 0) snprintf(time, 15, "(%02i:%02i-%02i:%02i)", start_value.hour, start_value.minute, end_value.hour, end_value.minute); rrule = icalcomponent_get_first_property(vevent,ICAL_RRULE_PROPERTY); if(rrule != 0) recur = icalproperty_get_rrule(rrule); else recur.freq = ICAL_NO_RECURRENCE; if(summary != NULL) summary_text = icalproperty_get_summary(summary); else summary_text = "NO SUMMARY FIELD FOR EVENT"; if(error_flag == 0 && recur.freq == ICAL_NO_RECURRENCE) { printf("%04i%02i%02i%s ", start_value.year, start_value.month, start_value.day, startstop); printf("%s %s\n", summary_text, time); good_event++; } else if(error_flag == 0 && recur.freq == ICAL_DAILY_RECURRENCE) { if(recur.interval == 1) printf("DAILY%s %s %s", startstop, summary_text, time); else error_flag = 1; } else if(error_flag == 0 && recur.freq == ICAL_YEARLY_RECURRENCE) { printf("0000%02i%02i ", start_value.month, start_value.day); printf("%s %s\n", summary_text, time); good_event++; } else if(error_flag == 0 && recur.freq == ICAL_WEEKLY_RECURRENCE) { if(recur.interval == 1) { switch(icalrecurrencetype_day_day_of_week(recur.by_day[0])) { case ICAL_SUNDAY_WEEKDAY: printf("SUN%s %s %s\n", startstop, summary_text, time); good_event++; break; case ICAL_MONDAY_WEEKDAY: printf("MON%s %s %s\n", startstop, summary_text, time); good_event++; break; case ICAL_TUESDAY_WEEKDAY: printf("TUE%s %s %s\n", startstop, summary_text, time); good_event++; break; case ICAL_WEDNESDAY_WEEKDAY: printf("WED%s %s %s\n", startstop, summary_text, time); good_event++; break; case ICAL_THURSDAY_WEEKDAY: printf("THU%s %s %s\n", startstop, summary_text, time); good_event++; break; case ICAL_FRIDAY_WEEKDAY: printf("FRI%s %s %s\n", startstop, summary_text, time); good_event++; break; case ICAL_SATURDAY_WEEKDAY: printf("SAT%s %s %s\n", startstop, summary_text, time); good_event++; break; default: error_flag = 1; break; } } else if(recur.interval == 52) { short n = recur.week_start; int weekday = -1; switch(icalrecurrencetype_day_day_of_week(recur.by_day[0])) { case ICAL_SUNDAY_WEEKDAY: weekday = 1; break; case ICAL_MONDAY_WEEKDAY: weekday = 2; break; case ICAL_TUESDAY_WEEKDAY: weekday = 3; break; case ICAL_WEDNESDAY_WEEKDAY: weekday = 4; break; case ICAL_THURSDAY_WEEKDAY: weekday = 5; break; case ICAL_FRIDAY_WEEKDAY: weekday = 6; break; case ICAL_SATURDAY_WEEKDAY: weekday = 7; break; default: error_flag = 1; break; } if(n>0) { printf("*%02i%1i%i%s ", start_value.month, n, weekday, startstop); printf("%s %s\n", summary_text, time); good_event++; } else if(n==-1) { printf("*%02iL%i%s ", start_value.month, weekday, startstop); printf("%s %s\n", summary_text, time); good_event++; } else error_flag = 1; } else error_flag = 1; } else if(error_flag == 0 && recur.freq == ICAL_MONTHLY_RECURRENCE) { if(recur.interval == 1) { if(recur.by_day[0] == ICAL_RECURRENCE_ARRAY_MAX) { printf("000000%02i%s %s %s\n", start_value.day, startstop, summary_text, time); good_event++; } else { short n = icalrecurrencetype_day_position(recur.by_day[0]); int weekday = -1; switch(icalrecurrencetype_day_day_of_week(recur.by_day[0])) { case ICAL_SUNDAY_WEEKDAY: weekday = 1; break; case ICAL_MONDAY_WEEKDAY: weekday = 2; break; case ICAL_TUESDAY_WEEKDAY: weekday = 3; break; case ICAL_WEDNESDAY_WEEKDAY: weekday = 4; break; case ICAL_THURSDAY_WEEKDAY: weekday = 5; break; case ICAL_FRIDAY_WEEKDAY: weekday = 6; break; case ICAL_SATURDAY_WEEKDAY: weekday = 7; break; default: error_flag = 1; break; } if(n>0) { printf("*00%1i%i%s ", n, weekday, startstop); printf("%s %s\n", summary_text, time); good_event++; } else if(n==-1) { printf("*00L%i%s ", weekday, startstop); printf("%s %s\n", summary_text, time); good_event++; } else error_flag = 1; } } else if(recur.interval == 12) { short n = icalrecurrencetype_day_position(recur.by_day[0]); int weekday = -1; switch(icalrecurrencetype_day_day_of_week(recur.by_day[0])) { case ICAL_SUNDAY_WEEKDAY: weekday = 1; break; case ICAL_MONDAY_WEEKDAY: weekday = 2; break; case ICAL_TUESDAY_WEEKDAY: weekday = 3; break; case ICAL_WEDNESDAY_WEEKDAY: weekday = 4; break; case ICAL_THURSDAY_WEEKDAY: weekday = 5; break; case ICAL_FRIDAY_WEEKDAY: weekday = 6; break; case ICAL_SATURDAY_WEEKDAY: weekday = 7; break; default: error_flag = 1; break; } if(n>0) { printf("*%02i%1i%i%s ", start_value.month, n, weekday, startstop); printf("%s %s\n", summary_text, time); good_event++; } else if(n==-1) { printf("*%02iL%i%s ", start_value.month, weekday, startstop); printf("%s %s\n", summary_text, time); good_event++; } else error_flag = 1; } else error_flag = 1; } else error_flag = 1; if(error_flag == 1) { fprintf(stderr, "Can't handle this yet:\n"); fprintf(stderr, "%s",icalcomponent_as_ical_string(vevent)); bad_event++; error_flag = 0; } vevent = icalcomponent_get_next_component(c, ICAL_VEVENT_COMPONENT); } fprintf(stderr, "Events converted: %i\n", good_event); fprintf(stderr, "Events that could not be converted: %i\n", bad_event); } int main(int argc, char* argv[]) { char* line; FILE* stream; icalcomponent *c; /* Create a new parser object */ icalparser *parser = icalparser_new(); if(argc != 4) { fprintf(stderr, "ical2pal %s - Copyright (C) 2004, Scott Kuhl\n", PAL_VERSION); fprintf(stderr, " %s", "pal is licensed under the GNU General Public License and has NO WARRANTY.\n\n"); fprintf(stderr, "Usage: ical2pal ical-file.ics CC EventType > pal-file.pal\n"); fprintf(stderr, " CC - 2 characters used to mark event in pal calendar.\n"); fprintf(stderr, " EventType - Description of the type of events in file.\n"); fprintf(stderr, "\n"); exit(1); } if(strlen(argv[2]) == 0) printf("__ "); else if(strlen(argv[2]) == 1) printf("%c_ ", *argv[2]); else printf("%c%c ", *argv[2], *(argv[2]+1)); printf("%s\n", argv[3]); stream = fopen(argv[1],"r"); assert(stream != 0); /* Tell the parser what input routine it should use. */ icalparser_set_gen_data(parser,stream); do{ /* Get a single content line by making one or more calls to read_stream()*/ line = icalparser_get_line(parser,read_stream); /* Now, add that line into the parser object. If that line completes a component, c will be non-zero */ c = icalparser_add_line(parser,line); if (c != 0) { output_pal_from_ical(c); icalcomponent_free(c); } } while (line != 0); icalparser_free(parser); fprintf(stderr, "DONE!\n\n"); fprintf(stderr, "NOTE: This program ignores the timezone settings in the ical calendar.\n"); fprintf(stderr, "Some events might not transfer because there is no equivalent event time\nin the pal calendar file format.\n"); return 0; } pal-0.4.3/src/convert/vcard2pal0000644000175000017500000000375011043370327016243 0ustar kleptogkleptog#!/usr/bin/awk -f # Copyright (c) 2005, 2008 Uli Martens # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # 3. The name of the author may not be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # version 0.9 # 2008-03-18 0.9 rewrote carriage return logic # The latest version can be found at http://youam.net/devel/vcard2pal/ BEGIN { FS=":"; print "** Birthday"; } /\r$/ { # skip carriage return at the end of the line $0=substr($0,0,length-1) } /^BEGIN:VCARD/ { fn = ""; palday=""; year=""; } /^FN/ { fn=$2 } /^BDAY/ { split( $2, date, "-" ); palday="0000" date[2] date[3]; if ( date[1] != "1900" ) year=" (!" date[1] "!)" } /^END:VCARD/ { if ( palday != "" ) print palday " " fn year } # vim: set tabstop=16: pal-0.4.3/src/convert/vcard2pal.10000644000175000017500000000240211043370327016373 0ustar kleptogkleptog.TH VCARD2PAL 1 .SH "NAME" vcard2pal \- convert vcard contacts into a pal calendar file .SH "SYNOPSIS" \fBvcard2pal \fI[filenames ...]\fR .SH "DESCRIPTION" .PP \fBvcard2pal\fR is a small \fBawk\fR script to convert vcard contacts into a calendar file for the \fBpal\fR calendar program. .SH "USAGE" Using \fBvcard2pal\fR is really simple, as it doesn't have any options. .PP You feed it some vcard formatted contacts either on stdin or give it the filenames of files which it should read and put the output of the script into a file which you then give to \fBpal\fR. .PP As \fBvcard2pal\fR needs no interactive input, you can also call it from \fBcron\fR or a makefile to always have an uptodate \fBpal\fR file generated from your contacts. .SH "BUGS" Please report bugs or fixes to Uli Martens . .SH "COPYING" \fBvcard2pal\fR is released under the example BSD license given in \fIhttp://www.debian.org/misc/bsd.license\fR. The full legalese can be found in \fBvcard2pal\fR. .PP The author is not responsible for any missed birthdays and subsequent family feuds, nor anything else. .SH "AUTHOR" \fBvcard2pal\fR was written by Uli Martens. This manpage has been written by Uli Martens and Carsten Hey and is published under the same terms as \fBvcard2pal\fR itself. pal-0.4.3/src/convert/Makefile0000644000175000017500000000255711043370327016106 0ustar kleptogkleptoginclude ../Makefile.defs INCLDIR = -I${prefix}/include `pkg-config --cflags glib-2.0` LIBDIR = SRC = ical2pal.c pal2ical.c OBJ = $(SRC:.c=.o) help: @echo "Please use one of the following targets:" @echo " ical Make ical <--> pal conversion utilities (requires libical)" @echo " ical-install Install ical <--> pal conversion utilities (requires libical)" @echo "" ical: ical2pal pal2ical ical2pal: ical2pal.o $(CC) $(CFLAGS) ical2pal.o -lical -lpthread -o ical2pal ifneq ($(DEBUG),1) strip ical2pal endif pal2ical: pal2ical.o cd .. && make libpal.a $(CC) $(CFLAGS) pal2ical.o -L.. -lpal `pkg-config --libs glib-2.0` -lreadline -lncurses -o pal2ical ifneq ($(DEBUG),1) strip pal2ical endif ical-debug: clean @$(MAKE) ical DEBUG=1 # Install binary file ical-install: @echo " --- Installing binary --- " @mkdir -p ${DESTDIR}${prefix}/bin; install -m 0755 -o root ical2pal ${DESTDIR}${prefix}/bin; install -m 0755 -o root pal2ical ${DESTDIR}${prefix}/bin; @echo # try to uninstall pal ical-uninstall: @echo " --- Removing binary --- " rm -f ${prefix}/bin/ical2pal; rm -f ${prefix}/bin/pal2ical; @echo # Remove binay, object files and emacs backup files clean: rm -f ical2pal pal2ical $(OBJ) *~ # Remove object files and dependency files cleandeps: clean rm -f $(SRC:.c=.d) cleandep: cleandeps splint: splint $(INCLDIR) $(SRC) pal-0.4.3/po/0000755000175000017500000000000011043370327012604 5ustar kleptogkleptogpal-0.4.3/po/sv.po0000644000175000017500000005567111043370327013612 0ustar kleptogkleptog# pal calendar - Swedish translation # Copyright (C) 2004 Lars Bjarby # This file is distributed under the same license as the pal package. # - Lars Bjarby , 2004. # # msgid "" msgstr "" "Project-Id-Version: se\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2004-05-14 15:45-0500\n" "PO-Revision-Date: 2004-10-08 21:10+0200\n" "Last-Translator: Lars Bjarby \n" "Language-Team: Swedish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);" #: main.c:86 main.c:347 msgid "tomorrow" msgstr "imorgon" #: main.c:92 main.c:347 msgid "yesterday" msgstr "igÃ¥r" #: main.c:98 main.c:347 msgid "today" msgstr "idag" #: main.c:104 msgid "mo" msgstr "mÃ¥" #: main.c:105 msgid "next mo" msgstr "nästa mÃ¥" #: main.c:111 msgid "tu" msgstr "ti" #: main.c:112 msgid "next tu" msgstr "nästa ti" #: main.c:118 msgid "we" msgstr "on" #: main.c:119 msgid "next we" msgstr "nästa on" #: main.c:125 msgid "th" msgstr "to" #: main.c:126 msgid "next th" msgstr "nästa to" #: main.c:132 msgid "fr" msgstr "fr" #: main.c:133 msgid "next fr" msgstr "nästa fr" #: main.c:139 msgid "sa" msgstr "lö" #: main.c:140 msgid "next sa" msgstr "nästa lö" #: main.c:145 msgid "su" msgstr "sö" #: main.c:146 msgid "next su" msgstr "nästa sö" #: main.c:152 msgid "last mo" msgstr "förra mÃ¥" #: main.c:158 msgid "last tu" msgstr "förra ti" #: main.c:164 msgid "last we" msgstr "förra on" #: main.c:170 msgid "last th" msgstr "förra to" #: main.c:176 msgid "last fr" msgstr "förra fr" #: main.c:182 msgid "last sa" msgstr "förra lö" #: main.c:188 msgid "last su" msgstr "förra sö" #: main.c:199 msgid "^[0-9]+ days away$" msgstr "^[0-9]+ dagar bort$" #: main.c:217 msgid "^[0-9]+ days ago$" msgstr "^[0-9]+ dagar sedan$" #: main.c:345 #, c-format msgid "ERROR: The following date is not valid: %s\n" msgstr "FEL: Följande datum är inte korrekt: %s\n" #: main.c:346 msgid "Valid date formats include:" msgstr "Giltiga datumformat inkluderar:" #: main.c:347 msgid "dd, mmdd, yyyymmdd," msgstr "dd, mmdd, ååååmmdd," #: main.c:348 msgid "'n days away', 'n days ago'," msgstr "'n dagar bort','n dagar sedan'," #: main.c:349 msgid "first two letters of weekday," msgstr "de första tvÃ¥ bokstäverna av en veckodag," #: main.c:350 msgid "'next ' followed by first two letters of weekday," msgstr "'nästa' följt av de tvÃ¥ första bokstäverna av en veckodag," #: main.c:351 msgid "'last ' followed by first two letters of weekday," msgstr "'förra ' följt av de tvÃ¥fösta bokstäverna av en veckodag," #: main.c:352 msgid "'1 Jan 2000', 'Jan 1 2000', etc." msgstr "'1 Jan 2000', 'Jan 1 2000', etc." #: main.c:372 msgid "" "NOTE: You can use -r to specify the range of days to search. By default, " "pal searches days within one year of today." msgstr "" "NOTIS: Du kan använda -r för att specifiera sökomrÃ¥det. Som standard, " "söker pal efter händelser frÃ¥n ett Ã¥r frÃ¥n idag." #: main.c:422 msgid "Copyright (C) 2004, Scott Kuhl" msgstr "Copyright (C) 2004, Scott Kuhl" #: main.c:425 msgid "" "pal is licensed under the GNU General Public License and has NO WARRANTY." msgstr "" "pal är licensierad under GNU General Public-licensen och har INGEN GARANTI." #: main.c:428 msgid "" " -d date Show events on the given date. Valid formats for date " "include: dd, mmdd, yyyymmdd, 'Jan 1 2000'. Run 'man pal' for a list of all " "valid formats." msgstr "" " -d datum Visa händelser pÃ¥ det givna datumet. Giltiga datumformat " "inkluderar: dd, mmdd, ååååmmdd, 'Jan 1 2000'. Kör 'man pal' för att fÃ¥ en " "lista pÃ¥ alla giltiga format." #: main.c:429 msgid "" " -r n Display events within n days after today or a date used with -" "d. (default: n=0, show nothing)" msgstr "" " -r n Visa hädelser som inträffar n dagar efter idag eller ett visst " "datum om -d används. (förvalt värde: n=0, visa ingenting)" #: main.c:430 msgid "" " -r p-n Display events within p days before and n days after today or " "a date used with -d." msgstr "" " -r p-n Visa händelser from p dagar före tom n dagar efter idag eller " "ett datum specificerat med -d." #: main.c:431 msgid "" " -s regex Search for events matching the regular expression. Use -r to " "select range of days to search." msgstr "" " -s regex Sök efter händelser som matchar det reguljära uttrycket. " "Använd -r för att välja mellan vilka dagar du vill söka." #: main.c:432 msgid " -x n Expunge events that are n or more days old." msgstr " -x b Radera händelser som är n eller fler dagar gamla." #: main.c:434 msgid " -c n Display calendar with n lines. (default: 5)" msgstr " -c n Visa kalender med n rader. (förvalt värde: 5)" #: main.c:435 msgid " -f file Load 'file' instead of ~/.pal/pal.conf" msgstr " -f fil\t Ladda 'fil' istället för ~/.pal/pal.conf" #: main.c:436 msgid " -u username Load /home/username/.pal/pal.conf" msgstr " -u användarnamn Ladda /home/användarnamn/.pal/pal.conf" #: main.c:437 msgid "" " -p palfile Load *.pal file only (overrides files loaded from pal.conf)" msgstr "" " -p pal-fil Ladda endast *.pal-fil (Ã¥sidosätter filer som laddas frÃ¥n pal." "conf)" #: main.c:438 msgid " -m Add/Modify/Delete events interactively." msgstr " -m Lägg/Modifiera/Radera till en händelse interaktivt." #: main.c:439 msgid " --color Force colors, regardless of terminal type." msgstr " --color SlÃ¥ pÃ¥ färger, oavsett terminaltyp." #: main.c:440 msgid " --nocolor Force no colors, regardless of terminal type." msgstr " --nocolor Stäng av färger, oavsett av terminaltyp." #: main.c:441 msgid " --mail Generate output readable by sendmail." msgstr " --mail Skapa utdata som kan användas av sendmail." #: main.c:442 msgid " --html Generate HTML calendar. Set size of calendar with -c." msgstr " --html Skapa HTML-kaldener. Bestäm kalenderns storlek med -c." #: main.c:443 msgid " --latex Generate LaTeX calendar. Set size of calendar with -c." msgstr " --latex Skapa LaTeX-kalender. Bestäm kalenderns storlek med -c." #: main.c:444 msgid " -v Verbose output." msgstr " -v Detaljerad utdata." #: main.c:445 msgid " --version Display version information." msgstr " --version Visa versionsinformation." #: main.c:446 msgid " -h, --help Display this help message." msgstr " -h, --help Visa detta hjälpmeddelande." #: main.c:449 msgid "Type \"man pal\" for more information." msgstr "Skriv \"man pal\" för mer information." #: main.c:464 msgid "ERROR: Number required after -r argument." msgstr "FEL: Ett nummer behövs efter -r argumentet." #: main.c:465 main.c:490 main.c:502 main.c:579 main.c:596 main.c:611 #: main.c:628 main.c:642 main.c:651 msgid "Use --help for more information." msgstr "Använd --help för mer information." #: main.c:489 msgid "ERROR: Number required after -c argument." msgstr "FEL: Ett nummer behövs efter -c argumentet." #: main.c:501 msgid "ERROR: Date required after -d argument." msgstr "FEL: Ett datum behövs efter -d argumentet." #: main.c:509 msgid "NOTE: Use quotes around the date if it has spaces.\n" msgstr "NOTIS: Använd citattecken runt datumet om det innehÃ¥ller mellanrum.\n" #: main.c:523 msgid "WARNING: -a is deprecated, use -m instead.\n" msgstr "VARNING: -a har utgÃ¥tt, använd -m istället.\n" #: main.c:568 #, c-format msgid "Compiled with prefix: %s\n" msgstr "Kompilerad med följande prefix: %s\n" #: main.c:578 msgid "ERROR: Pal conf file required after -f argument." msgstr "FEL: En Pal conf-fil behövs efter -f argumentet." #: main.c:595 msgid "ERROR: *.pal file required after -p argument." msgstr "FEL: En *.pal-fil behövs efter -p argumentet." #: main.c:610 msgid "ERROR: Username required after -u argument." msgstr "FEL: Ett användarnamn behövs efter -u argumentet." #: main.c:627 msgid "ERROR: Regular expression required after -s argument." msgstr "FEL: Ett reguljärtt uttryck behövs efter -s argumentet." #: main.c:641 msgid "ERROR: Number required after -x argument." msgstr "FEL: Ett tal behövs efter -x argumentet." #: main.c:650 msgid "ERROR: Bad argument:" msgstr "FEL: Felaktigt argument:" #: main.c:827 msgid "Manage events" msgstr "Hantera händelser" #: main.c:829 msgid "Press Control+c at any time to cancel.\n" msgstr "Tryck Control+C när som helst för att avbryta.\n" "" #: main.c:834 msgid "Add an event." msgstr "Lägg till en händelse." #: main.c:836 msgid "Edit an event." msgstr "Redigera en händelse." #: main.c:838 msgid "Delete an event." msgstr "Radera en händelse." #: main.c:840 msgid "Remind me about an event (with at/cron)." msgstr "PÃ¥minn mig om en händelse (med at/cron)." #: main.c:842 msgid "Exit." msgstr "Avsluta." #: main.c:844 msgid "Select action [1--5]: " msgstr "Välj [1--5]: " #: output.c:327 msgid "Mo Tu We Th Fr Sa Su" msgstr "MÃ¥ Ti On To Fr Lö Sö" #: output.c:329 msgid "Su Mo Tu We Th Fr Sa" msgstr "Sö MÃ¥ Ti On To Fr Lö" #: output.c:583 msgid "Today" msgstr "Idag" #: output.c:585 msgid "Tomorrow" msgstr "Imorgon" #: output.c:587 msgid "Yesterday" msgstr "IgÃ¥r" #: output.c:589 #, c-format msgid "%d days away" msgstr "%d dagar bort" #: output.c:591 #, c-format msgid "%d days ago" msgstr "%d dagar sedan" #: output.c:639 msgid "No events." msgstr "Inga händelser." #: input.c:188 #, c-format msgid "WARNING: File is missing 2 character marker and event type: %s\n" msgstr "VARNING: Filen saknar 2-teckensmarkör och händelsetyp: %s\n" #: input.c:207 msgid "ERROR: First line is improperly formatted.\n" msgstr "FEL: Första raden är felaktigt formaterad.\n" #: input.c:208 input.c:275 input.c:292 msgid "FILE" msgstr "FIL" #: input.c:210 input.c:276 input.c:293 msgid "LINE" msgstr "RAD" #: input.c:216 #, c-format msgid "ERROR: First line is not ASCII or UTF-8 in %s.\n" msgstr "FEL: Första raden i %s är inte ASCII eller UTF-8.\n" #: input.c:274 msgid "ERROR: Invalid date string.\n" msgstr "FEL: Felaktigt datumformat.\n" #: input.c:291 msgid "ERROR: Event description missing.\n" msgstr "FEL: Händelsebeskrivning saknas.\n" #: input.c:306 #, c-format msgid "ERROR: Event text '%s' is not ASCII or UTF-8 in file %s.\n" msgstr "FEL: Händelsetexten '%s' i %s är inte ASCII eller UTF-8.\n" #: input.c:339 msgid "Expunged" msgstr "Raderad" #: input.c:394 del.c:54 #, c-format msgid "ERROR: Can't write file: %s\n" msgstr "FEL: Kan inte skriva till filen: %s\n" #: input.c:395 #, c-format msgid "File will not be expunged: %s" msgstr "Filen kommer inte att bli raderad: %s" #: input.c:446 del.c:87 #, c-format msgid "ERROR: Can't rename %s to %s\n" msgstr "FEL: Kan inte döpa om %s till %s\n" #: input.c:465 #, c-format msgid "ERROR: File doesn't exist: %s\n" msgstr "FEL: Filen existerar inte: %s\n" #: input.c:488 #, c-format msgid "ERROR: Can't find file. I tried %s and %s.\n" msgstr "FEL: Kan inte hitta nÃ¥gon fil. Jag provade %s och %s.\n" #: input.c:511 #, c-format msgid "Reading: %s\n" msgstr "Läser: %s\n" #: input.c:514 del.c:46 #, c-format msgid "ERROR: Can't read file: %s\n" msgstr "FEL: Kan inte läsa frÃ¥n filen: %s\n" #: input.c:533 msgid "Looking for data to expunge.\n" msgstr "Letar efter data att radera.\n" #: input.c:542 #, c-format msgid "ERROR: Can't open file: %s\n" msgstr "FEL: Kan inte öppna filen: %s\n" #: input.c:555 #, c-format msgid "NOTE: Creating %s\n" msgstr "NOTIS: Skapar %s\n" #: input.c:556 msgid "" "NOTE: Edit ~/.pal/pal.conf to change how and if certain events are " "displayed.\n" msgstr "NOTIS: Redigera ./.pal/pal.conf f� att �dra hur och om vissa visas.\n" #: input.c:564 #, c-format msgid "ERROR: Can't create directory: %s\n" msgstr "FEL: Kan inte skapa katalog: %s\n" #: input.c:580 msgid "ERROR: Can't open file: /etc/pal.conf\n" msgstr "FEL: Kan inte öppna filen: /etc/pal.conf\n" #: input.c:581 msgid "ERROR: Can't open file: " msgstr "FEL: Kan inte öppna fil: " #: input.c:581 msgid "/share/pal/pal.conf\n" msgstr "/share/pal/pal.conf\n" #: input.c:582 msgid "ERROR: This indicates an improper installation.\n" msgstr "FEL: Detta indikerar en felaktig installation.\n" #: input.c:589 #, c-format msgid "ERROR: Can't create/write file: %s\n" msgstr "FEL: Kan inte skapa/skriva till fil: %s\n" #: input.c:663 input.c:712 #, c-format msgid "ERROR: Invalid color '%s' in file %s." msgstr "FEL: Felaktig färg '%s' i filen %s." #: input.c:665 input.c:714 msgid "Valid colors:" msgstr "Giltiga färger:" #: input.c:737 #, c-format msgid "ERROR: Invalid line (File: %s, Line text: %s)\n" msgstr "FEL: Ogiltig rad (Fil: %s, Radtext: %s)\n" #: input.c:744 #, c-format msgid "" "Done reading data (%d events, %d files).\n" "\n" msgstr "" "Färdig med inläsning av data (%d händelser, %d filer).\n" "\n" #: rl.c:69 msgid "WARNING: Failed to convert your input into UTF-8.\n" msgstr "VARNING: Misslyckades att konvertear din indata till UTF-8.\n" #: rl.c:75 msgid "Converted string to UTF-8." msgstr "Konverterade sträng till UTF-8." #: rl.c:93 rl.c:96 msgid "y" msgstr "j" #: rl.c:94 msgid "n" msgstr "n" #: rl.c:130 msgid "Use \"today\" to access TODO events." msgstr "Använd \"idag\" för att fÃ¥ tillgÃ¥ng till TODO-händelser." #: rl.c:133 rl.c:238 msgid "" "Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away" msgstr "" "Giltiga datumformat inkluderar: ååååmmdd, Jan 1 2000, 1 Jan 2000, 4 dagar bort" #: rl.c:135 msgid "Date for event or search string: " msgstr "Händelsens datum eller söktext: " #: rl.c:156 rl.c:190 msgid "Use \"0\" to use a different date or search string." msgstr "Använd \"0\" för att använda ett annat datum eller söktext" #: rl.c:158 rl.c:192 msgid "Select event number: " msgstr "Välj ett händelsenummer: " #: rl.c:172 rl.c:206 msgid "" "This event is in a global calendar file. You can change this event only by " "editing the global calendar file manually (root access might be required)." msgstr "" "Denna händelsen är i en global kalenderfil. Du kan endast ändra detta " "genom att regigera den globala kalenderfilen (detta kan kräva root access)." #: rl.c:240 msgid "Date for event: " msgstr "Händelsedatum: " #: rl.c:250 msgid "Events on the date you selected:\n" msgstr "Händelser pÃ¥ det datum du valde:\n" #: rl.c:257 msgid "Is this the correct date?" msgstr "Är detta det korrekta datumet?" #: rl.c:260 msgid "%a %e %b %Y - Accept? [y/n]: " msgstr "%a %e %b %Y - Acceptera? [j/n]: " #: html.c:66 html.c:76 latex.c:75 latex.c:85 msgid "Sunday" msgstr "Söndag" #: html.c:68 latex.c:77 msgid "Monday" msgstr "MÃ¥ndag" #: html.c:69 latex.c:78 msgid "Tuesday" msgstr "Tisdag" #: html.c:70 latex.c:79 msgid "Wednesday" msgstr "Onsdag" #: html.c:71 latex.c:80 msgid "Thursday" msgstr "Torsdag" #: html.c:72 latex.c:81 msgid "Friday" msgstr "Fredag" #: html.c:73 latex.c:82 msgid "Saturday" msgstr "Lördag" #: add.c:36 msgid "1st" msgstr "1:a" #: add.c:37 msgid "2nd" msgstr "2:a" #: add.c:38 msgid "3rd" msgstr "3:e" #: add.c:39 msgid "4th" msgstr "4:e" #: add.c:40 msgid "5th" msgstr "5:e" #: add.c:41 msgid "6th" msgstr "6:e" #: add.c:42 msgid "7th" msgstr "7:e" #: add.c:43 msgid "8th" msgstr "8:e" #: add.c:44 msgid "9th" msgstr "9:e" #: add.c:45 msgid "10th" msgstr "10:e" #: add.c:56 msgid "Does this event have starting and ending dates? " msgstr "Har den här händelsen start- och slutdatum? " #: add.c:58 add.c:129 msgid "[y/n]: " msgstr "[j/n]: " #: add.c:76 add.c:98 msgid "Start date: " msgstr "Startdatum: " #: add.c:83 add.c:100 msgid "End date: " msgstr "Slutdatum: " #: add.c:90 msgid "ERROR: The end date is the same as or before the start date.\n" msgstr "FEL: Slutdatumet är samma som eller innan startdatumet.\n" #: add.c:102 msgid "Accept? [y/n]:" msgstr "Acceptera? [j/n]:" #: add.c:125 msgid "Is the event recurring? " msgstr "Är händelsen Ã¥terkommande? " #: add.c:138 msgid "Select how often this event occurs\n" msgstr "Välj hur ofta den här händelsen inträffar\n" #: add.c:141 msgid "- Daily\n" msgstr "- Dagligen\n" #: add.c:145 #, c-format msgid "- Weekly: Every %s\n" msgstr "- Veckovis: Varje %s\n" #: add.c:148 #, c-format msgid "- Monthly: Day %d of every month\n" msgstr "- MÃ¥nadsvis: Dag %d i varje mÃ¥nad\n" #: add.c:154 #, c-format msgid "- Monthly: The %s %s of every month\n" msgstr "- MÃ¥nadsvis: Den %s %s i varje mÃ¥nad\n" #: add.c:159 #, c-format msgid "- Annually: %d %s\n" msgstr "- Ã…rligen: %d %s\n" #: add.c:166 #, c-format msgid "- Annually: The %s %s of every %s\n" msgstr "- Ã…rligen: Den %s %s i varje %s\n" #: add.c:176 #, c-format msgid "- Monthly: The last %s of every month\n" msgstr "- MÃ¥nadsvis: Den sista %s i varje mÃ¥nad\n" #: add.c:181 #, c-format msgid "- Annually: The last %s in %s\n" msgstr "- Ã…rligen: Den sista %s i %s\n" #: add.c:189 msgid "Select type [1--8]: " msgstr "Välj typ [1--8]: " #: add.c:191 msgid "Select type [1--6]: " msgstr "Välj typ [1--6]: " #: add.c:323 msgid "What is the description of this event?\n" msgstr "Vad är beskrivningen för denna händelse?\n" #: add.c:332 edit.c:48 msgid "Description: " msgstr "Beskrivning: " #: add.c:335 edit.c:51 msgid "Is this description correct? [y/n]: " msgstr "Är den här beskrivningen korrekt? [j/n]: " #: add.c:348 msgid "Calendar file (usually ending with \".pal\") to add event to:\n" msgstr "" "Kalenderfil (slutar vanligtvis med \".pal\") att lägga till händelsen i:\n" #: add.c:383 #, c-format msgid "ERROR: %s is a directory.\n" msgstr "FEL: %s är en katalog.\n" #: add.c:390 #, c-format msgid "WARNING: %s does not exist.\n" msgstr "VARNING: %s existerar inte.\n" #: add.c:392 msgid "Create? [y/n]: " msgstr "Skapa? [j/n]: " #: add.c:400 #, c-format msgid "ERROR: Can't create %s.\n" msgstr "FEL: Kan inte skapa %s.\n" #: add.c:411 #, c-format msgid "Information for %s:\n" msgstr "Information om %s:\n" #: add.c:413 msgid "2 character marker for calendar: " msgstr "2-teckens markör för kalendern: " #: add.c:416 msgid "Calendar title: " msgstr "Kalendertitel: " #: add.c:422 msgid "" "If you want events in this new calendar file to appear when you run pal,\n" " you need to manually update ~/.pal/pal.conf" msgstr "" "Om du vill att händelser i den här nya kalenderfilen skall visas när du\n" "kör pal mÃ¥ste du uppdatera ~/.pal/pal.conf manuellt" #: add.c:456 #, c-format msgid "ERROR: Can't read from file %s.\n" msgstr "FEL: Kan inte läsa frÃ¥n filen %s\n" #: add.c:457 add.c:474 msgid "Try again? [y/n]: " msgstr "Försöka igen? [j/n]" #: add.c:473 #, c-format msgid "ERROR: Can't write to file %s.\n" msgstr "FEL: Kan inte skriva till filen %s\n" #: add.c:487 #, c-format msgid "Wrote new event \"%s %s\" to %s.\n" msgstr "Sparade en ny händelse: \"%s %s\" i %s.\n" #: add.c:500 msgid "" "Use \"TODO\" to make an event that always occurs on the current date. If " "the event is recurring, select one of the days the event occurs on." msgstr "" "Använd \"TODO\" för att skapa en händelse som alltid inträffar pÃ¥ dagens " "datum. Om händelsen är Ã¥terkommande; välj en av dagarna dÃ¥ händelsen " "inträffar." #: add.c:519 msgid "Add an event" msgstr "Lägg till en händelse" #: edit.c:39 msgid "What is the new description of this event?\n" msgstr "Vad är beskrivningen för denna händelse?\n" #: edit.c:59 msgid "Editing the event:\n" msgstr "Redigerar händelsen:\n" #: edit.c:67 msgid "Edit the event date (how often it happens, start date, end date)." msgstr "Redigera händelsedatumet (hur ofta det händer, start-, slutdatum)." #: edit.c:69 msgid "Edit the event description." msgstr "Redigera händelsebeskrivningen." #: edit.c:71 msgid "Select action [1--2]: " msgstr "Välj [1--2]: " #: edit.c:103 msgid "Edit an event" msgstr "Redigera en händelse." #: del.c:47 del.c:55 del.c:88 msgid " The event was NOT deleted." msgstr " Den här händelsen har INTE raderats." #: del.c:96 #, c-format msgid "Event removed from %s.\n" msgstr "Händelse raderad frÃ¥n: %s.\n" #: del.c:99 #, c-format msgid "ERROR: Couldn't find event to be deleted in %s" msgstr "FEL: Kunde inte hitta nÃ¥gon händelse att radera i %s" #: del.c:110 msgid "Delete an event" msgstr "Radera en händelse" #: del.c:114 msgid "" "If you want to delete old events that won't occur again, you can use pal's -" "x option instead of deleting the events manually." msgstr "" "Om du vill radera gamla händelser som inte kommer inträffa igen kan du" "använda pal:s x-alternativ istället för att radera händelserna manuellt." #: del.c:120 msgid "You have selected to delete the following event:\n" msgstr "Du har valt att radera följande händelse:\n" #: del.c:123 msgid "Are you sure you want to delete this event? [y/n]: " msgstr "Är du säker pÃ¥ att du vill radera den här händelsen? [j/n]: " #: remind.c:64 msgid "Event reminder" msgstr "HändelsepÃ¥minnelse" #: remind.c:68 msgid "" "This feature allows you to select one event and have an email sent to you " "about the event at a date/time that you provide. If the event is recurring, " "you will only receive one reminder. You MUST have atd, crond and sendmail " "installed and working for this feature to work." msgstr "" "Den här funktionen lÃ¥ter dig välja en händelse och fÃ¥ ett e-post skickat till " "dig om den pÃ¥ en tid/datum som du väljer. Om det är en upprepande " "händelse kommer du bara att fÃ¥ en pÃ¥minnelse. Du MÃ…STE ha atd, crond" "och sendmail installerande och fungerande för att det här skall fungera." #: remind.c:97 msgid "Remind me on (HH:MM YYYY-MM-DD): " msgstr "PÃ¥minn mig (HH:MM Ã…Ã…Ã…Ã…-MM-DD): " #: remind.c:102 msgid "Username on local machine or email address: " msgstr "Användarnamn pÃ¥ den här datorn eller en e-postadress: " #: remind.c:123 msgid "Event: " msgstr "Händelse: " #: remind.c:127 msgid "Event date: " msgstr "Händelsedatum: " #: remind.c:136 msgid "Event type: " msgstr "Händelsetyp: " #: remind.c:145 msgid "Attempting to run 'at'...\n" msgstr "Försöker att köra 'at'...\n" #: remind.c:150 msgid "" "ERROR: Date string was invalid or could not run 'at'. Is 'atd' running?" msgstr "" "FEL: Datumformatet var ej korrekt eller sÃ¥ gick det ej att köra 'at'. Är 'atd' igÃ¥ng?" #: remind.c:154 msgid "Successfully added event to the 'at' queue.\n" msgstr "Lade till händelsen till 'at'-kön.\n" #: search.c:106 #, c-format msgid "" "[ Begin search results: %s ]\n" "[ From %s to %s inclusive ]\n" "\n" msgstr "" "[ Börja sökresultat: %s ]\n" "[ FrÃ¥n %s till och med %s]\n" "\n" #: search.c:163 #, c-format msgid "[ End search results: %s ] [ %d %s found ]\n" msgstr "[ Avsluta sökresultat: %s ] [ %d %s hittade ]\n" #~ msgid "" #~ "ERROR: When using -s, use -r to specify the range to search within.\n" #~ msgstr "FEL: När -s används, använd -r för att specifiera sökomrÃ¥det.\n" #~ msgid "WARNING: File is empty: %s\n" #~ msgstr "VARNING: Filen är tom: %s\n" #~ msgid "- Annually: On day %d of every %s\n" #~ msgstr "- Ã…rligen: PÃ¥ dag %d i varje %s\n" #~ msgid "Is this the date you want to add an event to?\n" #~ msgstr "Är det här det datumet du vill lägga till en händelse pÃ¥?\n" #~ msgid "Add another event? [y/n]: " #~ msgstr "Lägga till en annan händelse? [j/n]" pal-0.4.3/po/de.po0000644000175000017500000006035611043370327013546 0ustar kleptogkleptog# pal calendar - translation to German # This file is distributed under the same license as the pal package. # Scott Kuhl, 2004. # Copyright (C) 2004,2005 Christopher Knörle . # Christopher Knoerle , 2005. # # msgid "" msgstr "" "Project-Id-Version: de\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2005-01-30 16:32+0100\n" "PO-Revision-Date: 2006-06-07 18:08+0100\n" "Last-Translator: Bastian Kleineidam \n" "Language-Team: German\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #: main.c:84 #: main.c:345 msgid "tomorrow" msgstr "morgen" #: main.c:90 #: main.c:345 msgid "yesterday" msgstr "Gestern" #: main.c:96 #: main.c:345 msgid "today" msgstr "Heute" #: main.c:102 msgid "mo" msgstr "Mo" #: main.c:103 msgid "next mo" msgstr "nächsten Mo" #: main.c:109 msgid "tu" msgstr "Di" #: main.c:110 msgid "next tu" msgstr "nächsten Di" #: main.c:116 msgid "we" msgstr "Mi" #: main.c:117 msgid "next we" msgstr "nächsten Mi" #: main.c:123 msgid "th" msgstr "Do" #: main.c:124 msgid "next th" msgstr "nächsten Do" #: main.c:130 msgid "fr" msgstr "Fr" #: main.c:131 msgid "next fr" msgstr "nächsten Fr" #: main.c:137 msgid "sa" msgstr "Sa" #: main.c:138 msgid "next sa" msgstr "nächsten Sa" #: main.c:143 msgid "su" msgstr "So" #: main.c:144 msgid "next su" msgstr "nächsten So" #: main.c:150 msgid "last mo" msgstr "letzten Mo" #: main.c:156 msgid "last tu" msgstr "letzten Di" #: main.c:162 msgid "last we" msgstr "letzten Mi" #: main.c:168 msgid "last th" msgstr "letzten Do" #: main.c:174 msgid "last fr" msgstr "letzten Fr" #: main.c:180 msgid "last sa" msgstr "letzten Sa" #: main.c:186 msgid "last su" msgstr "letzten So" #: main.c:197 msgid "^[0-9]+ days away$" msgstr "in [0-9]+ Tagen$" #: main.c:215 msgid "^[0-9]+ days ago$" msgstr "vor [0-9]+ Tagen$" #: main.c:343 #, c-format msgid "ERROR: The following date is not valid: %s\n" msgstr "FEHLER: Das folgende Datum ist ungültig: %s\n" #: main.c:344 msgid "Valid date formats include:" msgstr "Gültige Datumsformate sind:" #: main.c:345 msgid "dd, mmdd, yyyymmdd," msgstr "dd, mmdd, yyyymmdd," #: main.c:346 msgid "'n days away', 'n days ago'," msgstr "'in n Tagen', 'vor n Tagen'," #: main.c:347 msgid "first two letters of weekday," msgstr "den ersten beiden Buchstaben des Wochentags (auf En)," #: main.c:348 msgid "'next ' followed by first two letters of weekday," msgstr "'next ' gefolgt von den ersten beiden Buchstaben des Wochentags (auf En)," #: main.c:349 msgid "'last ' followed by first two letters of weekday," msgstr "'last ' gefolgt von den ersten beiden Buchstaben des Wochentags (auf En)," #: main.c:350 msgid "'1 Jan 2000', 'Jan 1 2000', etc." msgstr "'1 Jan 2000', 'Jan 1 2000', etc." #: main.c:370 msgid "NOTE: You can use -r to specify the range of days to search. By default, pal searches days within one year of today." msgstr "ANMERKUNG: Mit -r kann ein Zeitraum von Tagen angegeben werden. Normalerweise durchsucht pal einen Zeitraum von einem Jahr." #: main.c:420 msgid "Copyright (C) 2004, Scott Kuhl" msgstr "Copyright (C) 2004, Scott Kuhl" #: main.c:423 msgid "pal is licensed under the GNU General Public License and has NO WARRANTY." msgstr "pal ist licensed under the GNU General Public License and has NO WARRANTY." #: main.c:426 msgid " -d date Show events on the given date. Valid formats for date include: dd, mmdd, yyyymmdd, 'Jan 1 2000'. Run 'man pal' for a list of all valid formats." msgstr " -d Datum Ereignisse am gegebenen Datum anzeigen. Gültige Formate: dd, mmdd, yyyymmdd, '1 Jan 2000'. 'man pal' listet alle gültigen Formate auf." #: main.c:427 msgid " -r n Display events within n days after today or a date used with -d. (default: n=0, show nothing)" msgstr " -r n Ereignisse der nächsten n Tage nach heute oder einem Datum -d anzeigen. (Standard: n=0, nichts zeigen)" #: main.c:428 msgid " -r p-n Display events within p days before and n days after today or a date used with -d." msgstr " -r p-n Ereignisse der p Tage vor und n Tage nach heute oder einem Datum -d anzeigen." #: main.c:429 msgid " -s regex Search for events matching the regular expression. Use -r to select range of days to search." msgstr " -s regex Nach einem auf einen regulären Ausdruck passenden Ereignis suchen. Zur Angabe eines Zeitraums -r benutzen." #: main.c:430 msgid " -x n Expunge events that are n or more days old." msgstr " -x n Ereignisse löschen, die n oder mehr Tage alt sind." #: main.c:432 msgid " -c n Display calendar with n lines. (default: 5)" msgstr " -c n Kalender mit n Zeilen anzeigen. (Standard: 5)" #: main.c:433 msgid " -f file Load 'file' instead of ~/.pal/pal.conf" msgstr " -f Datei 'Datei' an Stelle von ~/.pal/pal.conf laden." #: main.c:434 msgid " -u username Load /home/username/.pal/pal.conf" msgstr " -u Name /home/Name/.pal/pal.conf laden." #: main.c:435 msgid " -p palfile Load *.pal file only (overrides files loaded from pal.conf)" msgstr " -p Datei Nur Datei.pal laden (hebt die Angaben aus pal.conf auf)" #: main.c:436 msgid " -m Add/Modify/Delete events interactively." msgstr " -m Ereignisse interaktiv hinzufügen/verändern/löschen." #: main.c:437 msgid " --color Force colors, regardless of terminal type." msgstr " --color Farben anzeigen, Terminaltyp nicht beachten." #: main.c:438 msgid " --nocolor Force no colors, regardless of terminal type." msgstr " --nocolor keine Farben anzeigen, Terminaltyp nicht beachten." #: main.c:439 msgid " --mail Generate output readable by sendmail." msgstr " --mail Ausgabe für sendmail erzeugen." #: main.c:440 msgid " --html Generate HTML calendar. Set size of calendar with -c." msgstr " --html html Tabelle ausgeben. Kalendergröße mit -c angeben." #: main.c:441 msgid " --latex Generate LaTeX calendar. Set size of calendar with -c." msgstr " --latex LaTeX Tabelle ausgeben. Kalendergröße mit -c angeben." #: main.c:442 msgid " -v Verbose output." msgstr " -v detaillierte Ausgabe." #: main.c:443 msgid " --version Display version information." msgstr " --version Versionsinformation anzeigen." #: main.c:444 msgid " -h, --help Display this help message." msgstr " -h, --help Diesen Hilfetext anzeigen." #: main.c:447 msgid "Type \"man pal\" for more information." msgstr "Für mehr Informationen \"man pal\" eingeben." #: main.c:462 msgid "ERROR: Number required after -r argument." msgstr "FEHLER: Nummer nach -r benötigt." #: main.c:463 #: main.c:488 #: main.c:500 #: main.c:577 #: main.c:594 #: main.c:609 #: main.c:626 #: main.c:640 #: main.c:649 msgid "Use --help for more information." msgstr "Für mehr Informationen --help verwenden." #: main.c:487 msgid "ERROR: Number required after -c argument." msgstr "FEHLER: Nummer nach -c benötigt" #: main.c:499 msgid "ERROR: Date required after -d argument." msgstr "FEHLER: Datum nach -d benötigt." #: main.c:507 msgid "NOTE: Use quotes around the date if it has spaces.\n" msgstr "" "ANMERKUNG: Wenn das Datum Leerzeichen enthält\n" " muss es in Anführungszeichen gesetzt werden.\n" #: main.c:521 msgid "WARNING: -a is deprecated, use -m instead.\n" msgstr "WARNUNG: -a ist veraltet, stattdessen -m benutzen.\n" #: main.c:566 #, c-format msgid "Compiled with prefix: %s\n" msgstr "Kompiliert mit Präfix: %s\n" #: main.c:576 msgid "ERROR: Pal conf file required after -f argument." msgstr "FEHLER: Pal Konfigurationsdatei nach -f benötigt." #: main.c:593 msgid "ERROR: *.pal file required after -p argument." msgstr "FEHLER: *.pal Datei nach -p benötigt." #: main.c:608 msgid "ERROR: Username required after -u argument." msgstr "FEHLER: Benutzername nach -u benötigt." #: main.c:625 msgid "ERROR: Regular expression required after -s argument." msgstr "FEHLER: Regulärer Ausdruck nach -s benötigt." #: main.c:639 msgid "ERROR: Number required after -x argument." msgstr "FEHLER: Nummer nach -x benötigt." #: main.c:648 msgid "ERROR: Bad argument:" msgstr "FEHLER: Ungültiges Argument:" #: output.c:316 msgid "Mo Tu We Th Fr Sa Su" msgstr "Mo Di Mi Do Fr Sa So" #: output.c:318 msgid "Su Mo Tu We Th Fr Sa" msgstr "So Mo Di Mi Do Fr Sa" #: output.c:551 #: manage.c:68 msgid "Today" msgstr "Heute" #: output.c:553 #: manage.c:70 msgid "Tomorrow" msgstr "Morgen" #: output.c:555 #: manage.c:72 msgid "Yesterday" msgstr "Gestern" #: output.c:557 #: manage.c:74 #, c-format msgid "%d days away" msgstr "in %d Tagen" #: output.c:559 #: manage.c:76 #, c-format msgid "%d days ago" msgstr "vor %d Tagen" #: output.c:609 msgid "No events." msgstr "Keine Ereignisse." #: input.c:188 #, c-format msgid "WARNING: File is missing 2 character marker and event type: %s\n" msgstr "WARNUNG: Datei enthält keine 2-Zeichen-Markierung und Ereignistyp: %s\n" #: input.c:207 msgid "ERROR: First line is improperly formatted.\n" msgstr "FEHLER: Erste Zeile ist falsch formatiert.\n" #: input.c:208 #: input.c:275 #: input.c:292 msgid "FILE" msgstr "DATEI" #: input.c:210 #: input.c:276 #: input.c:293 msgid "LINE" msgstr "ZEILE" #: input.c:216 #, c-format msgid "ERROR: First line is not ASCII or UTF-8 in %s.\n" msgstr "FEHLER: Erste Zeile von %s ist nicht ASCII oder UTF-8.\n" #: input.c:274 msgid "ERROR: Invalid date string.\n" msgstr "FEHLER: Ungültiges Datum.\n" #: input.c:291 msgid "ERROR: Event description missing.\n" msgstr "FEHLER: Fehlende Ereignisbeschreibung.\n" #: input.c:306 #, c-format msgid "ERROR: Event text '%s' is not ASCII or UTF-8 in file %s.\n" msgstr "FEHLER: Ereignistext '%s' in Datei %s ist nicht ASCII oder UTF-8.\n" #: input.c:329 msgid "Expunged" msgstr "Gelöscht" #: input.c:384 #: del.c:53 #, c-format msgid "ERROR: Can't write file: %s\n" msgstr "FEHLER: Datei %s kann nicht geschrieben werden.\n" #: input.c:385 #, c-format msgid "File will not be expunged: %s" msgstr "Datei %s wird nicht gelöscht." #: input.c:436 #: del.c:86 #, c-format msgid "ERROR: Can't rename %s to %s\n" msgstr "FEHLER: %s kann nicht in %s umbenannt werden.\n" #: input.c:455 #, c-format msgid "ERROR: File doesn't exist: %s\n" msgstr "FEHLER: Datei %s existiert nicht.\n" #: input.c:478 #, c-format msgid "ERROR: Can't find file. I tried %s and %s.\n" msgstr "FEHLER: Datei kann weder als %s noch als %s gefunden werden.\n" #: input.c:501 #, c-format msgid "Reading: %s\n" msgstr "Lese %s\n" #: input.c:504 #: del.c:45 #, c-format msgid "ERROR: Can't read file: %s\n" msgstr "FEHLER: Datei %s kann nicht gelesen werden.\n" #: input.c:523 msgid "Looking for data to expunge.\n" msgstr "Suche nach Daten zum Löschen.\n" #: input.c:532 #, c-format msgid "ERROR: Can't open file: %s\n" msgstr "FEHLER: Datei %s kann nicht geöffnet werden.\n" #: input.c:545 #, c-format msgid "NOTE: Creating %s\n" msgstr "ANMERKUNG: %s wird erstellt.\n" #: input.c:546 msgid "NOTE: Edit ~/.pal/pal.conf to change how and if certain events are displayed.\n" msgstr "ANMERKUNG: In ~/.pal/pal.conf kann die Art der Anzeige bestimmter Ereignisse geändert werden.\n" #: input.c:554 #, c-format msgid "ERROR: Can't create directory: %s\n" msgstr "FEHLER: Verzeichnis %s kann nicht erstellt werden.\n" #: input.c:570 msgid "ERROR: Can't open file: /etc/pal.conf\n" msgstr "FEHLER: /etc/pal.conf kann nicht geöffnet werden.\n" #: input.c:571 msgid "ERROR: Can't open file: " msgstr "FEHLER: Datei kann nicht geöffnet werden: " #: input.c:571 msgid "/share/pal/pal.conf\n" msgstr "/share/pal/pal.conf\n" #: input.c:572 msgid "ERROR: This indicates an improper installation.\n" msgstr "FEHLER: Das ist ein Hinweis auf eine falsche Installation.\n" #: input.c:579 #, c-format msgid "ERROR: Can't create/write file: %s\n" msgstr "FEHLER: Datei %s kann nicht erstellt/geschrieben werden.\n" #: input.c:653 #: input.c:702 #, c-format msgid "ERROR: Invalid color '%s' in file %s." msgstr "FEHLER: Ungültige Farbe '%s' in Datei %s." #: input.c:655 #: input.c:704 msgid "Valid colors:" msgstr "Gültige Farben:" #: input.c:727 #, c-format msgid "ERROR: Invalid line (File: %s, Line text: %s)\n" msgstr "FEHLER: Ungültige Zeile (Datei: %s, Text: %s)\n" #: input.c:734 #, c-format msgid "" "Done reading data (%d events, %d files).\n" "\n" msgstr "Lesen der Daten beendet (%d Ereignisse, %d Dateien).\n" #: rl.c:84 msgid "WARNING: Failed to convert your input into UTF-8.\n" msgstr "WARNUNG: Umwandeln der Eingabe in UTF-8 fehlgeschlagen.\n" #: rl.c:90 msgid "Converted string to UTF-8." msgstr "Zeichenfolge in UTF-8 umgewandelt." #: rl.c:108 #: rl.c:111 msgid "y" msgstr "y" #: rl.c:109 msgid "n" msgstr "n" #: rl.c:145 msgid "Use \"today\" to access TODO events." msgstr "Zum Zugriff auf TODO Ereignisse \"today\" benutzen." #: rl.c:148 #: rl.c:253 msgid "Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away" msgstr "Gültige Formate sind: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away" #: rl.c:150 msgid "Date for event or search string: " msgstr "Datum des Ereignisses oder Suchwort: " #: rl.c:171 #: rl.c:205 msgid "Use \"0\" to use a different date or search string." msgstr "Für ein anderes Datum oder Suchwort \"0\" eingeben." #: rl.c:173 #: rl.c:207 msgid "Select event number: " msgstr "Ereignisnummer auswählen: " #: rl.c:187 #: rl.c:221 msgid "This event is in a global calendar file. You can change this event only by editing the global calendar file manually (root access might be required)." msgstr "Dieses Ereignis befindet sich in einem globalen Kalender. Es kann nur durch manuelles Editieren der globalen Kalenderdatei geändert werden (evtl. wird root-Zugriff benötigt)." #: rl.c:255 msgid "Date for event: " msgstr "Datum des Ereignisses: " #: rl.c:265 msgid "Events on the date you selected:\n" msgstr "Ereignisse am gewählten Datum:\n" #: rl.c:272 msgid "Is this the correct date?" msgstr "Ist das Datum korrekt" #: rl.c:275 msgid "%a %e %b %Y - Accept? [y/n]: " msgstr "%a %e %b %Y - Akzeptieren? [y/n]: " #: html.c:66 #: html.c:76 #: latex.c:75 #: latex.c:85 msgid "Sunday" msgstr "Sonntag" #: html.c:68 #: latex.c:77 msgid "Monday" msgstr "Montag" #: html.c:69 #: latex.c:78 msgid "Tuesday" msgstr "Dienstag" #: html.c:70 #: latex.c:79 msgid "Wednesday" msgstr "Mittwoch" #: html.c:71 #: latex.c:80 msgid "Thursday" msgstr "Donnerstag" #: html.c:72 #: latex.c:81 msgid "Friday" msgstr "Freitag" #: html.c:73 #: latex.c:82 msgid "Saturday" msgstr "Samstag" #: add.c:33 msgid "1st" msgstr "1." #: add.c:34 msgid "2nd" msgstr "1." #: add.c:35 msgid "3rd" msgstr "3." #: add.c:36 msgid "4th" msgstr "4." #: add.c:37 msgid "5th" msgstr "5." #: add.c:38 msgid "6th" msgstr "6." #: add.c:39 msgid "7th" msgstr "7." #: add.c:40 msgid "8th" msgstr "8." #: add.c:41 msgid "9th" msgstr "9." #: add.c:42 msgid "10th" msgstr "10." #: add.c:53 msgid "Does this event have starting and ending dates? " msgstr "Hat dieses Ereignis ein Anfangs- und End-Datum? " #: add.c:55 #: add.c:126 msgid "[y/n]: " msgstr "[y/n]: " #: add.c:73 #: add.c:95 msgid "Start date: " msgstr "Anfangsdatum: " #: add.c:80 #: add.c:97 msgid "End date: " msgstr "Enddatum: " #: add.c:87 msgid "ERROR: The end date is the same as or before the start date.\n" msgstr "FEHLER: Das Enddatum muss nach dem Startdatum liegen.\n" #: add.c:99 msgid "Accept? [y/n]:" msgstr "Akzeptieren? [y/n]:" #: add.c:122 msgid "Is the event recurring? " msgstr "Wiederholt sich das Ereignis? " #: add.c:135 msgid "Select how often this event occurs\n" msgstr "Wie oft wiederholt sich das Ereignis?\n" #: add.c:138 msgid "- Daily\n" msgstr "- täglich\n" #: add.c:142 #, c-format msgid "- Weekly: Every %s\n" msgstr "- wöchentlich: jeden %s\n" #: add.c:145 #, c-format msgid "- Monthly: Day %d of every month\n" msgstr "- monatlich: am %d jedes Monats\n" #: add.c:151 #, c-format msgid "- Monthly: The %s %s of every month\n" msgstr "- monatlich: der %s %s jedes Monats\n" #: add.c:156 #, c-format msgid "- Annually: %d %s\n" msgstr "- jährlich: %d %s\n" #: add.c:163 #, c-format msgid "- Annually: The %s %s of every %s\n" msgstr "- jährlich: am %s %s jeden %s\n" #: add.c:173 #, c-format msgid "- Monthly: The last %s of every month\n" msgstr "- monatlich: am letzten %s jedes Monats\n" #: add.c:178 #, c-format msgid "- Annually: The last %s in %s\n" msgstr "- jährlich: am letzten %s im %s\n" #: add.c:186 msgid "Select type [1--8]: " msgstr "Typ auswählen [1--8]: " #: add.c:188 msgid "Select type [1--6]: " msgstr "Typ auswählen [1--6]: " #: add.c:320 msgid "What is the description of this event?\n" msgstr "Eine Beschreibung für dieses Ereignis?\n" #: add.c:329 msgid "Description: " msgstr "Beschreibung: " #: add.c:332 msgid "Is this description correct? [y/n]: " msgstr "Ist diese Beschreibung richtig? [y/n]: " #: add.c:345 msgid "Calendar file (usually ending with \".pal\") to add event to:\n" msgstr "Kalenderdatei (endet normalerweise mit \".pal\") zum Hinzufügen des Ereignisses:\n" #: add.c:380 #, c-format msgid "ERROR: %s is a directory.\n" msgstr "FEHLER: %s ist ein Verzeichnis.\n" #: add.c:387 #, c-format msgid "WARNING: %s does not exist.\n" msgstr "WARNUNG: %s existiert nicht\n" #: add.c:389 msgid "Create? [y/n]: " msgstr "Erstellen? [y/n]: " #: add.c:397 #, c-format msgid "ERROR: Can't create %s.\n" msgstr "FEHLER: %s kann nicht erstellt werden.\n" #: add.c:408 #, c-format msgid "Information for %s:\n" msgstr "Information für %s:\n" #: add.c:410 msgid "2 character marker for calendar: " msgstr "Markierung des Kalenders (2 Zeichen): " #: add.c:413 msgid "Calendar title: " msgstr "Titel des Kalenders: " #: add.c:419 msgid "" "If you want events in this new calendar file to appear when you run pal,\n" " you need to manually update ~/.pal/pal.conf" msgstr "" "Wenn die Ereignisse dieser Datei von pal angezeigt werden sollen,\n" " muss ~./pal/pal.conf manuell angepasst werden." #: add.c:453 #, c-format msgid "ERROR: Can't read from file %s.\n" msgstr "FEHLER: Aus Datei %s kann nicht gelesen werden.\n" #: add.c:454 #: add.c:471 msgid "Try again? [y/n]: " msgstr "Erneut versuchen? [y/n]: " #: add.c:470 #, c-format msgid "ERROR: Can't write to file %s.\n" msgstr "FEHLER: Die Datei %s kann nicht geschrieben werden.\n" #: add.c:484 #, c-format msgid "Wrote new event \"%s %s\" to %s.\n" msgstr "Neues Ereignis \"%s %s\" nach %s geschrieben.\n" #: add.c:497 msgid "Use \"TODO\" to make an event that always occurs on the current date. If the event is recurring, select one of the days the event occurs on." msgstr "Für ein Ereignis, das immer zum aktuellen Datum erscheint \"TODO\" benutzen. Wenn sich das Ereignis wiederholt muss ein Tag ausgewählt werden." #: add.c:516 msgid "Add an event" msgstr "Ereignis hinzufügen" #: edit.c:41 msgid "Edit event description: " msgstr "Ereignisbeschreibung bearbeiten: " #: edit.c:51 msgid "Editing the event:\n" msgstr "Bearbeiten des Ereignisses:\n" #: edit.c:59 msgid "Edit the event date (how often it happens, start date, end date)." msgstr "Bearbeiten des Datums (Wiederholungen, Anfangsdatum, Enddatum)." #: edit.c:61 msgid "Edit the event description." msgstr "Ereignisbeschreibung bearbeiten." #: edit.c:63 msgid "Select action [1--2]: " msgstr "Aktion auswählen [1--2]: " #: edit.c:95 msgid "Edit an event" msgstr "Ereignis bearbeiten" #: del.c:46 #: del.c:54 #: del.c:87 msgid " The event was NOT deleted." msgstr " Das Ereignis wurde NICHT gelöscht." #: del.c:95 #, c-format msgid "Event removed from %s.\n" msgstr "Ereignis entfernt aus %s.\n" #: del.c:98 #, c-format msgid "ERROR: Couldn't find event to be deleted in %s" msgstr "FEHLER: Zu löschendes Ereignis konnte nicht in %s gefunden werden." #: del.c:109 msgid "Delete an event" msgstr "Ereignis löschen" #: del.c:113 msgid "If you want to delete old events that won't occur again, you can use pal's -x option instead of deleting the events manually." msgstr "Wenn alte Ereignisse, die nicht mehr vorkommen gelöscht werden sollen, kann pal's Option x benutzt werden, statt diese händisch zu löschen." #: del.c:119 msgid "You have selected to delete the following event:\n" msgstr "Das folgende Ereignis wurde zum Löschen ausgewählt:\n" #: del.c:122 msgid "Are you sure you want to delete this event? [y/n]: " msgstr "Soll dieses Ereignis wirklich gelöscht werden? [y/n]: " #: remind.c:63 msgid "Event reminder" msgstr "Erinnerungsfunktion" #: remind.c:67 msgid "This feature allows you to select one event and have an email sent to you about the event at a date/time that you provide. If the event is recurring, you will only receive one reminder. You MUST have atd, crond and sendmail installed and working for this feature to work." msgstr "Dieses Feature ermöglicht das Senden einer Mail zu einer bestimmten Zeit zur Erinnerung an ein Ereignis. Falls sich das Ereignis wiederholt, wird nur eine Erinnerung verschickt. Es müssen atd, crond und sendmail installiert sein, damit das funktioniert." #: remind.c:96 msgid "Remind me on (HH:MM YYYY-MM-DD): " msgstr "Zeitpunkt der Erinnerung (HH:MM YYYY-MM-DD): " #: remind.c:101 msgid "Username on local machine or email address: " msgstr "Lokaler Benutzername oder email Adresse: " #: remind.c:122 msgid "Event: " msgstr "Ereignis: " #: remind.c:126 msgid "Event date: " msgstr "Datum des Ereignisses: " #: remind.c:135 msgid "Event type: " msgstr "Art des Ereignisses: " #: remind.c:144 msgid "Attempting to run 'at'...\n" msgstr "Versuche 'at' auszuführen...\n" #: remind.c:149 msgid "ERROR: Date string was invalid or could not run 'at'. Is 'atd' running?" msgstr "FEHLER: Datumsformat ungültig oder 'at' konnte nicht ausgeführt werden. Läuft der 'atd'?" #: remind.c:153 msgid "Successfully added event to the 'at' queue.\n" msgstr "Ereignis erfolgreich zu 'at' hinzugefügt.\n" #: search.c:106 #, c-format msgid "" "[ Begin search results: %s ]\n" "[ From %s to %s inclusive ]\n" "\n" msgstr "" "[ Anfang der Suchergebnisse: %s ]\n" "[ Von %s bis %s inklusive ]\n" "\n" #: search.c:163 #, c-format msgid "[ End search results: %s ] [ %d %s found ]\n" msgstr "[ Ende der Suchergebnisse: %s ] [ %d %s gefunden ]\n" #: manage.c:62 msgid "Selected day:" msgstr "Gewählter Tag:" #: manage.c:176 msgid "Press 'h' for help, 'q' to quit." msgstr "'h' für Hilfe, 'q' zum Beenden." #: manage.c:249 msgid "Goto date:" msgstr "Zum Datum: " #: manage.c:280 msgid "Can't edit global event!" msgstr "Globale Ereignisse können nicht bearbeitet werden!" #: manage.c:322 msgid "Can't delete global event!" msgstr "Globales Ereignis kann nicht gelöscht werden!" #: manage.c:354 msgid "Quit" msgstr "Beenden" #: manage.c:355 msgid "RightArrow" msgstr "PfeilRechts" #: manage.c:355 msgid "Forward one day" msgstr "nächster Tag" #: manage.c:356 msgid "LeftArrow" msgstr "PfeilLinks" #: manage.c:356 msgid "Back one day" msgstr "voriger Tag" #: manage.c:357 msgid "Toggle event selection" msgstr "Ereignis Auswahl setzen" #: manage.c:358 msgid "DownArrow" msgstr "PfeilUnten" #: manage.c:358 msgid "Forward one week or event (if in event selection mode)" msgstr "Nächste Woche oder Ereignis (bei Ereignis Auswahl)" #: manage.c:359 msgid "UpArrow" msgstr "PfeilOben" #: manage.c:359 msgid "Back one week or event (if in event selection mode)" msgstr "Vorige Woche oder Ereignis (bei Ereignis Auswahl)" #: manage.c:360 msgid "This help screen." msgstr "Diese Hilfe." #: manage.c:361 msgid "Jump to a specific date." msgstr "Zu einem bestimmten Datum springen." #: manage.c:362 msgid "JumpGoto a specific date." msgstr "JumpGoto " #: manage.c:364 msgid "Edit description for selected event." msgstr "Beschreibung des Ereignisses bearbeiten." #: manage.c:365 msgid "Edit date for selected event." msgstr "Datum des Ereignisses bearbeiten." #: manage.c:367 msgid "Add an event to selected date." msgstr "Ereignis zum Datum hinzufügen." #: manage.c:368 msgid "Delete selected event." msgstr "Ereignis löschen." #: manage.c:370 msgid "Search for event." msgstr "Ereignis suchen." #: manage.c:371 msgid "Remind me about an event" msgstr "Erinnerung für ein Ereignis" #: manage.c:374 msgid "Press any key to exit help." msgstr "Beliebige Taste zum Beenden der Hilfe." #~ msgid "Manage events" #~ msgstr "Ereignisse verwalten" #~ msgid "Press Control+c at any time to cancel.\n" #~ msgstr "Zum Abbrechen Strg+c drücken.\n" #~ msgid "Exit." #~ msgstr "Beenden." #~ msgid "Select action [1--5]: " #~ msgstr "Aktion auswählen [1--5]: " #~ msgid "What is the new description of this event?\n" #~ msgstr "Neue Beschreibung für dieses Ereignis?\n" pal-0.4.3/po/README0000644000175000017500000000670611043370327013475 0ustar kleptogkleptogThis document describes how you can translate pal into other languages. NOTE: Some parts of pal rely on other libraries already have different translations available. If pal isn't translated to your language, a few parts of it, such as the names of the months, will be translated. If you have any questions about this document or if you find a mistake in it, please email the palcal-devel mailing list (for more information, see http://palcal.sourceforge.net/). 0) Create po/pal.pot by running "make pot" while in /src 1) Look for a file named "language_COUNTRY.po" in this directory, where "language" is the two character code for your language and "COUNTRY" is the two character code for your country. If you don't want to make a country specific translation, just use "language.po". 1a) If this file does not exist, create it by copying "pal.pot" to "language_COUNTRY.po". 1b) If the file already exists, run the command: msgmerge language_COUNTRY.po pal.pot > language_COUNTRY.po.NEW mv language_COUNTRY.po.NEW language_COUNTRY.po This command will merge any updated strings that need to be translated in pal.pot into language_COUNTRY.po. 2) Add translations for as many of the strings as possible. The original strings are labeled "msgid". The string to be translated is labeled "msgstr". Duplicate the formatting strings (such as %s) in your translated strings. Try to duplicate any spacing in your translated strings as well. 3) If you didn't create a new language_COUNTRY.po file, also look for translated strings that are marked "fuzzy". If the translation for a "fuzzy" string is good, remove the "fuzzy" label from it. If the translation is bad, fix it and remove the "fuzzy" label from it. 4) Update the header for the po file where appropriate: 4a) Remove the "fuzzy" label before the header. 4b) Update "PO-Revision-Date" with the date you edited the file. 4c) Update "Last-Translator" with your name and email address. 4d) Update "Language-Team" with: LANGUAGE => Full name of language for translation LL => Language code 4e) Update "Content-Type" with charset=UTF-8 4f) If it exists, replace this line: # Copyright (C) YEAR Scott Kuhl with # Copyright (C) CURRENT_YEAR YOUR NAME If the line does not exist, add a new copyright line under the copyright line that is already there. 5) CHECK your po file with this command and fix any problems: msgfmt -c --statistics language_COUNTRY.po 6) TEST. You can test your translation by running the following command as root (depending on your distribution, you might need to replace /usr with /usr/local in the commands below): mkdir -p /usr/share/locale/language_COUNTRY/LC_MESSAGES/ msgfmt language_COUNTRY.po -o /usr/share/locale/language_COUNTRY/LC_MESSAGES/pal.mo For both of the commands above, you will need to replace language_COUNTRY with your locale code. You do not need to run the first command if the directory already exists. Then, you should be able to run "LC_ALL=language_COUNTRY pal" to test your translation. 7) SUBMIT. Run "gzip language_COUNTRY.po" and attach your language_COUNTRY.po.gz file to an email to the palcal-devel mailing list (information about this mailing list can be found on pal's website, http://palcal.sourceforge.net/). Your translation will likely be added to the next release of pal. pal-0.4.3/po/es.po0000644000175000017500000006007511043370327013563 0ustar kleptogkleptog# pal calendar # Copyright (C) 2004 Scott Kuhl # Copyright (C) 2004 Javier Linares # This file is distributed under the same license as the pal package. # Scott Kuhl, 2004. # # msgid "" msgstr "" "Project-Id-Version: pal 0.3.4_pre1\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2004-04-29 17:55+0200\n" "PO-Revision-Date: 2004-04-29 18:07+0200\n" "Last-Translator: Javier Linares \n" "Language-Team: Spanish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #: main.c:86 main.c:347 msgid "tomorrow" msgstr "mañana" #: main.c:92 main.c:347 msgid "yesterday" msgstr "ayer" #: main.c:98 main.c:347 msgid "today" msgstr "hoy" #: main.c:104 msgid "mo" msgstr "lu" #: main.c:105 msgid "next mo" msgstr "próximo lu" #: main.c:111 msgid "tu" msgstr "ma" #: main.c:112 msgid "next tu" msgstr "próximo ma" #: main.c:118 msgid "we" msgstr "mi" #: main.c:119 msgid "next we" msgstr "próximo mi" #: main.c:125 msgid "th" msgstr "ju" #: main.c:126 msgid "next th" msgstr "próximo ju" #: main.c:132 msgid "fr" msgstr "vi" #: main.c:133 msgid "next fr" msgstr "próximo vi" #: main.c:139 msgid "sa" msgstr "sa" #: main.c:140 msgid "next sa" msgstr "próximo sa" #: main.c:145 msgid "su" msgstr "do" #: main.c:146 msgid "next su" msgstr "próximo do" #: main.c:152 msgid "last mo" msgstr "último lu" #: main.c:158 msgid "last tu" msgstr "último ma" #: main.c:164 msgid "last we" msgstr "último mi" #: main.c:170 msgid "last th" msgstr "último ju" #: main.c:176 msgid "last fr" msgstr "último vi" #: main.c:182 msgid "last sa" msgstr "último sa" #: main.c:188 msgid "last su" msgstr "último do" #: main.c:199 msgid "^[0-9]+ days away$" msgstr "en ^[0-9]+ días$" #: main.c:217 msgid "^[0-9]+ days ago$" msgstr "hace ^[0-9]+ días$" #: main.c:345 #, c-format msgid "ERROR: The following date is not valid: %s\n" msgstr "ERROR: La siguiente fecha no es válida: %s\n" #: main.c:346 msgid "Valid date formats include:" msgstr "Diferentes formatos para la fecha pueden ser:" #: main.c:347 msgid "dd, mmdd, yyyymmdd," msgstr "dd, mmdd, aaaammdd," #: main.c:348 msgid "'n days away', 'n days ago'," msgstr "'en n días', 'hace n días'," #: main.c:349 msgid "first two letters of weekday," msgstr "primeras dos letras del día de la semana," #: main.c:350 msgid "'next ' followed by first two letters of weekday," msgstr "'próximo ' seguido de las dos primeras letras del día de la semana," #: main.c:351 msgid "'last ' followed by first two letters of weekday," msgstr "'último ' seguido de las dos primeras letras del día de la semana," #: main.c:352 msgid "'1 Jan 2000', 'Jan 1 2000', etc." msgstr "'1 Ene 2000', 'Ene 1 2000', etc." #: main.c:372 msgid "" "NOTE: You can use -r to specify the range of days to search. By default, " "pal searches days within one year of today." msgstr "" "NOTA: Puede usar -r para especificar el rando de días en el que buscar. " "Por omisión, pal busca en un año." #: main.c:422 msgid "Copyright (C) 2004, Scott Kuhl" msgstr "Copyright (C) 2004, Scott Kuhl" #: main.c:425 msgid "" "pal is licensed under the GNU General Public License and has NO WARRANTY." msgstr "" "pal está licenciado bajo la Licencia Pública General GNU y NO tiene GARANTíA." #: main.c:428 msgid "" " -d date Show events on the given date. Valid formats for date " "include: dd, mmdd, yyyymmdd, 'Jan 1 2000'. Run 'man pal' for a list of all " "valid formats." msgstr "" " -d fecha Muestra los eventos relacionados con esa fecha. Son formatos " "válidos para la fecha: dd, mmdd, aaaammdd, 'Ene 1 2000'. Teclee 'man pal' " "para obtener una lista de todos los formatos válidos." #: main.c:429 msgid "" " -r n Display events within n days after today or a date used with -" "d. (default: n=0, show nothing)" msgstr "" " -r n Muestra eventos en los n días siguientes a hoy o a la fecha " "especificada por el parámetro -d. (por omisión: n=0, no mostrar nada)" #: main.c:430 msgid "" " -r p-n Display events within p days before and n days after today or " "a date used with -d." msgstr "" " -r p-n Muestra eventos en los p días anteriores y los n days " "posteriores a hoy o a la fecha especificada con -d." #: main.c:431 msgid "" " -s regex Search for events matching the regular expression. Use -r to " "select range of days to search." msgstr "" " -s regex Muestra eventos que coincidan con la expersión regular. Use -r " "para seleccionar el rango de días en el que buscar." #: main.c:432 msgid " -x n Expunge events that are n or more days old." msgstr "" " -x n Elimina eventos que tienen n días o más de n días de " "antigüedad." #: main.c:434 msgid " -c n Display calendar with n lines. (default: 5)" msgstr " -c n Muestra el calendario con n líneas. (predeterminado: 5)" #: main.c:435 msgid " -f file Load 'file' instead of ~/.pal/pal.conf" msgstr " -f archivo Carga 'archivo' en lugar de ~/.pal/pal.conf" #: main.c:436 msgid " -u username Load /home/username/.pal/pal.conf" msgstr " -u usuario Carga /home/usuario/.pal/pal.conf" #: main.c:437 msgid "" " -p palfile Load *.pal file only (overrides files loaded from pal.conf)" msgstr "" " -p palfile Sólo carga el archivo *.pal (sobrescribe los archivos cargados " "desde pal.conf)" #: main.c:438 msgid " -m Add/Modify/Delete events interactively." msgstr " -m Añade/Modifica/Elimina eventos de forma interactiva." #: main.c:439 msgid " --color Force colors, regardless of terminal type." msgstr "" " --color Fuerza la salida en color, sin tener el cuenta el tipo de " "terminal." #: main.c:440 msgid " --nocolor Force no colors, regardless of terminal type." msgstr "" " --nocolor Fuerza la salida sin colores, sin tener en cuenta el tipo de " "terminal." #: main.c:441 msgid " --mail Generate output readable by sendmail." msgstr " --mail Genera salida que puede ser entendida por sendmail." #: main.c:442 msgid " --html Generate HTML calendar. Set size of calendar with -c." msgstr "" " --html Genera calendario en HTML. Especifique el tamaño del " "calendario con -c." #: main.c:443 msgid " --latex Generate LaTeX calendar. Set size of calendar with -c." msgstr "" " --latex Genera calendario en LaTeX. Especifique el tamaño del " "calendario con -c." #: main.c:444 msgid " -v Verbose output." msgstr " -v Salida detallada." #: main.c:445 msgid " --version Display version information." msgstr " --version Muestra información sobre la versión." #: main.c:446 msgid " -h, --help Display this help message." msgstr " -h, --help Muestra este mensaje de ayuda." #: main.c:449 msgid "Type \"man pal\" for more information." msgstr "Teclee \"man pal\" para más información." #: main.c:464 msgid "ERROR: Number required after -r argument." msgstr "ERROR: Es necesario especificar un número tras el argumento -r." #: main.c:465 main.c:490 main.c:502 main.c:579 main.c:596 main.c:611 #: main.c:628 main.c:642 main.c:651 msgid "Use --help for more information." msgstr "Use --help para más información." #: main.c:489 msgid "ERROR: Number required after -c argument." msgstr "ERROR: Es necesario especificar un número tras el argumento -c." #: main.c:501 msgid "ERROR: Date required after -d argument." msgstr "ERROR: Es necesario especificar una fecha tras el argumento -d." #: main.c:509 msgid "NOTE: Use quotes around the date if it has spaces.\n" msgstr "NOTA: Use comillas en la fecha si ésta contiene espacios.\n" #: main.c:523 msgid "WARNING: -a is deprecated, use -m instead.\n" msgstr "AVISO: -a es obsoleta, use -m en su lugar.\n" #: main.c:568 #, c-format msgid "Compiled with prefix: %s\n" msgstr "Compilado con prefijo: %s\n" #: main.c:578 msgid "ERROR: Pal conf file required after -f argument." msgstr "" "ERROR: Es necesario especificar un archivo de configuración de pal tras el " "argumento -f." #: main.c:595 msgid "ERROR: *.pal file required after -p argument." msgstr "ERROR: Es necesario especificar un archivo *.pal tras el argumento -p." #: main.c:610 msgid "ERROR: Username required after -u argument." msgstr "" "ERROR: Es necesario especificar un nombre de usuario tras el argumento -u." #: main.c:627 msgid "ERROR: Regular expression required after -s argument." msgstr "" "ERROR: Es necesario incluir una expresión regular tras el argumento -s." #: main.c:641 msgid "ERROR: Number required after -x argument." msgstr "ERROR: Es necesario especificar un número tras el argumento -x." #: main.c:650 msgid "ERROR: Bad argument:" msgstr "ERROR: Argumento incorrecto." #: main.c:827 msgid "Manage events" msgstr "Gestionar eventos" #: main.c:829 msgid "Press Control+c at any time to cancel.\n" msgstr "Presione Control+c en cualquier momento para cancelar.\n" #: main.c:834 msgid "Add an event." msgstr "Añadir un evento." #: main.c:836 msgid "Edit an event." msgstr "Editar un evento." #: main.c:838 msgid "Delete an event." msgstr "Eliminar un evento." #: main.c:840 msgid "Remind me about an event (with at/cron)." msgstr "Enviar aviso sobre el evento (con at/cron)." #: main.c:842 msgid "Exit." msgstr "Salir." #: main.c:844 msgid "Select action [1--5]: " msgstr "Seleccione acción [1--5]: " #: output.c:327 msgid "Mo Tu We Th Fr Sa Su" msgstr "Lu Ma Mi Ju Vi Sa Do" #: output.c:329 msgid "Su Mo Tu We Th Fr Sa" msgstr "Do Lu Ma Mi Ju Vi Sa" #: output.c:583 msgid "Today" msgstr "Hoy" #: output.c:585 msgid "Tomorrow" msgstr "Mañana" #: output.c:587 msgid "Yesterday" msgstr "Ayer" #: output.c:589 #, c-format msgid "%d days away" msgstr "en %d días" #: output.c:591 #, c-format msgid "%d days ago" msgstr "hace %d días" #: output.c:639 msgid "No events." msgstr "No hay eventos." #: input.c:188 #, c-format msgid "WARNING: File is missing 2 character marker and event type: %s\n" msgstr "" "ADVERTENCIA: El archivo no contiene 2 caracteres para marcar el evento, ni " "el tipo de evento: %s\n" #: input.c:207 msgid "ERROR: First line is improperly formatted.\n" msgstr "ERROR: Primera línea con formato incorreto.\n" #: input.c:208 input.c:275 input.c:292 msgid "FILE" msgstr "ARCHIVO" #: input.c:210 input.c:276 input.c:293 msgid "LINE" msgstr "LINEA" #: input.c:216 #, c-format msgid "ERROR: First line is not ASCII or UTF-8 in %s.\n" msgstr "ERROR: La primera línea no es ASCII ni UTF-8 en %s.\n" #: input.c:274 msgid "ERROR: Invalid date string.\n" msgstr "ERROR: Cadena de fecha incorrecta.\n" #: input.c:291 msgid "ERROR: Event description missing.\n" msgstr "ERROR: Descripción del evento no especificada.\n" #: input.c:306 #, c-format msgid "ERROR: Event text '%s' is not ASCII or UTF-8 in file %s.\n" msgstr "" "ERROR: El texto del evento '%s' no es ASCII ni UTF-8 in el archivo %s.\n" #: input.c:339 msgid "Expunged" msgstr "Eliminado" #: input.c:394 del.c:54 #, c-format msgid "ERROR: Can't write file: %s\n" msgstr "ERROR: No es posible escribir en el archivo: %s\n" #: input.c:395 #, c-format msgid "File will not be expunged: %s" msgstr "El archivo no será eliminado: %s" #: input.c:446 del.c:87 #, c-format msgid "ERROR: Can't rename %s to %s\n" msgstr "ERROR: No es posible renombrar %s a %s\n" #: input.c:465 #, c-format msgid "ERROR: File doesn't exist: %s\n" msgstr "ERROR: El archivo no existe: %s\n" #: input.c:488 #, c-format msgid "ERROR: Can't find file. I tried %s and %s.\n" msgstr "ERROR: Archivo no encontrado. Se ha intentado %s y %s.\n" #: input.c:511 #, c-format msgid "Reading: %s\n" msgstr "Leyendo: %s\n" #: input.c:514 del.c:46 #, c-format msgid "ERROR: Can't read file: %s\n" msgstr "ERROR: No es posible leer el archivo: %s\n" #: input.c:533 msgid "Looking for data to expunge.\n" msgstr "Buscando datos para eliminar.\n" #: input.c:542 #, c-format msgid "ERROR: Can't open file: %s\n" msgstr "ERROR: No es posible abrir el archivo: %s\n" #: input.c:555 #, c-format msgid "NOTE: Creating %s\n" msgstr "NOTA: Crenado %s\n" #: input.c:556 msgid "" "NOTE: Edit ~/.pal/pal.conf to change how and if certain events are " "displayed.\n" msgstr "" "NOTA: Edite ~/.pal/pal.conf para cambiar qué eventos son mostrados, y el " "formato de los mismos.\n" #: input.c:564 #, c-format msgid "ERROR: Can't create directory: %s\n" msgstr "ERROR: No es posible crear directorio: %s\n" #: input.c:580 msgid "ERROR: Can't open file: /etc/pal.conf\n" msgstr "ERROR: No es posible abrir el archivo /etc/pal.conf\n" #: input.c:581 msgid "ERROR: Can't open file: " msgstr "ERROR: No es posible abrir el archivo: " #: input.c:581 msgid "/share/pal/pal.conf\n" msgstr "/share/pal/pal.conf\n" #: input.c:582 msgid "ERROR: This indicates an improper installation.\n" msgstr "ERROR: Esto indica una instalación defectuosa.\n" #: input.c:589 #, c-format msgid "ERROR: Can't create/write file: %s\n" msgstr "ERROR: No es posible crear/escribir el fichero: %s\n" #: input.c:663 input.c:712 #, c-format msgid "ERROR: Invalid color '%s' in file %s." msgstr "ERROR: Color '%s' no válido en el archivo %s." #: input.c:665 input.c:714 msgid "Valid colors:" msgstr "Colores válidos:" #: input.c:737 #, c-format msgid "ERROR: Invalid line (File: %s, Line text: %s)\n" msgstr "ERROR: Línea no válida (Archivo: %s, Línea: %s)\n" #: input.c:744 #, c-format msgid "" "Done reading data (%d events, %d files).\n" "\n" msgstr "" "Lectura de los datos finalizada (%d eventos, %d archivos).\n" "\n" #: rl.c:69 msgid "WARNING: Failed to convert your input into UTF-8.\n" msgstr "AVISO: Error al convertir la entrada a UTF-8.\n" #: rl.c:75 msgid "Converted string to UTF-8." msgstr "Cadena convertida a UTF-8." #: rl.c:93 rl.c:96 msgid "y" msgstr "s" #: rl.c:94 msgid "n" msgstr "n" #: rl.c:130 msgid "Use \"today\" to access TODO events." msgstr "Use \"hoy\" para acceder a los eventos TODO." #: rl.c:133 rl.c:238 msgid "" "Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away" msgstr "" "Formatos válidos incluyen: aaaammdd, Ene 1 2000, 1 Ene 2000, en 4 días" #: rl.c:135 msgid "Date for event or search string: " msgstr "Fecha del evento o cadena a buscar: " #: rl.c:156 rl.c:190 msgid "Use \"0\" to use a different date or search string." msgstr "Use \"0\" para utilizar una fecha diferente o buscar una cadena." #: rl.c:158 rl.c:192 msgid "Select event number: " msgstr "Seleccione el número del evento: " #: rl.c:172 rl.c:206 msgid "" "This event is in a global calendar file. You can change this event only by " "editing the global calendar file manually (root access might be required)." msgstr "" "Este evento está en un archivo de calendario global. Sólo puede cambiarlo " "editando el archivo de calendario global manualmente (se requiere acceso " "root)." #: rl.c:240 msgid "Date for event: " msgstr "Fecha del evento: " #: rl.c:250 msgid "Events on the date you selected:\n" msgstr "Eventos en la fecha seleccionada:\n" #: rl.c:257 msgid "Is this the correct date?" msgstr "¿La fecha es correcta?" #: rl.c:260 msgid "%a %e %b %Y - Accept? [y/n]: " msgstr "%a %e %b %Y - ¿Aceptar? [s/n]: " #: html.c:151 html.c:161 latex.c:75 latex.c:85 msgid "Sunday" msgstr "Domingo" #: html.c:153 latex.c:77 msgid "Monday" msgstr "Lunes" #: html.c:154 latex.c:78 msgid "Tuesday" msgstr "Martes" #: html.c:155 latex.c:79 msgid "Wednesday" msgstr "Miércoles" #: html.c:156 latex.c:80 msgid "Thursday" msgstr "Jueves" #: html.c:157 latex.c:81 msgid "Friday" msgstr "Viernes" #: html.c:158 latex.c:82 msgid "Saturday" msgstr "Sábado" #: add.c:36 msgid "1st" msgstr "1º" #: add.c:37 msgid "2nd" msgstr "2º" #: add.c:38 msgid "3rd" msgstr "3º" #: add.c:39 msgid "4th" msgstr "4º" #: add.c:40 msgid "5th" msgstr "5º" #: add.c:41 msgid "6th" msgstr "6º" #: add.c:42 msgid "7th" msgstr "7º" #: add.c:43 msgid "8th" msgstr "8º" #: add.c:44 msgid "9th" msgstr "9º" #: add.c:45 msgid "10th" msgstr "10º" #: add.c:56 msgid "Does this event have starting and ending dates? " msgstr "¿Este evento tiene fecha de inicio y finalización? " #: add.c:58 add.c:129 msgid "[y/n]: " msgstr "[s/n]: " #: add.c:76 add.c:98 msgid "Start date: " msgstr "Fecha de inicio: " #: add.c:83 add.c:100 msgid "End date: " msgstr "Fecha de finalización: " #: add.c:90 msgid "ERROR: The end date is the same as or before the start date.\n" msgstr "" "ERROR: La fecha de finalización es anterior o igual a la fecha de inicio.\n" #: add.c:102 msgid "Accept? [y/n]:" msgstr "¿Es correcto? [y/n]:" #: add.c:125 msgid "Is the event recurring? " msgstr "¿El evento es periódico? " #: add.c:138 msgid "Select how often this event occurs\n" msgstr "Seleccione la frecuencia del evento\n" #: add.c:141 msgid "- Daily\n" msgstr "- A diario\n" #: add.c:145 #, c-format msgid "- Weekly: Every %s\n" msgstr "- Semanal: Todos los %s\n" #: add.c:148 #, c-format msgid "- Monthly: Day %d of every month\n" msgstr "- Mensual: Día %d de todos los meses\n" #: add.c:154 #, c-format msgid "- Monthly: The %s %s of every month\n" msgstr "- Mensual: El %s %s de cada mes\n" #: add.c:159 #, c-format msgid "- Annually: %d %s\n" msgstr "- Anual: %d %s\n" #: add.c:166 #, c-format msgid "- Annually: The %s %s of every %s\n" msgstr "- Anual: El %s %s de todos los %s\n" #: add.c:176 #, c-format msgid "- Monthly: The last %s of every month\n" msgstr "- Mensual: El último %s de todos los meses\n" #: add.c:181 #, c-format msgid "- Annually: The last %s in %s\n" msgstr "- Anual: El último %s de %s\n" #: add.c:189 msgid "Select type [1--8]: " msgstr "Seleccione el tipo [1--8]: " #: add.c:191 msgid "Select type [1--6]: " msgstr "Seleccione el tipo [1--6]: " #: add.c:323 msgid "What is the description of this event?\n" msgstr "¿Cuál es la descripción del evento?\n" #: add.c:332 edit.c:48 msgid "Description: " msgstr "Descripción: " #: add.c:335 edit.c:51 msgid "Is this description correct? [y/n]: " msgstr "¿Es la descripción correcta? [s/n]: " #: add.c:348 msgid "Calendar file (usually ending with \".pal\") to add event to:\n" msgstr "" "Archivo de calendario (normalmente con extensión \".pal\") al que añadir el " "evento:\n" #: add.c:383 #, c-format msgid "ERROR: %s is a directory.\n" msgstr "ERROR: %s es un directorio.\n" #: add.c:390 #, c-format msgid "WARNING: %s does not exist.\n" msgstr "AVISO: %s no existe.\n" #: add.c:392 msgid "Create? [y/n]: " msgstr "¿Crear? [s/n]: " #: add.c:400 #, c-format msgid "ERROR: Can't create %s.\n" msgstr "ERROR: No es posible crear %s.\n" #: add.c:411 #, c-format msgid "Information for %s:\n" msgstr "Información sobre %s:\n" #: add.c:413 msgid "2 character marker for calendar: " msgstr "2 caracteres para marcar el evento en el calendario: " #: add.c:416 msgid "Calendar title: " msgstr "Título del calendario: " #: add.c:422 msgid "" "If you want events in this new calendar file to appear when you run pal,\n" " you need to manually update ~/.pal/pal.conf" msgstr "" "Si desea que los eventos de este calendario aparezcan al ejecutar pal,\n" " necesita actualizar a mano el archivo ~/.pal/pal.conf" #: add.c:456 #, c-format msgid "ERROR: Can't read from file %s.\n" msgstr "ERROR: No es posible leer el archivo %s.\n" #: add.c:457 add.c:474 msgid "Try again? [y/n]: " msgstr "¿Intentar de nuevo? [s/n]: " #: add.c:473 #, c-format msgid "ERROR: Can't write to file %s.\n" msgstr "ERROR: No es posible escribir en el archivo %s.\n" #: add.c:487 #, c-format msgid "Wrote new event \"%s %s\" to %s.\n" msgstr "Evento \"%s %s\" escrito a %s.\n" #: add.c:500 msgid "" "Use \"TODO\" to make an event that always occurs on the current date. If " "the event is recurring, select one of the days the event occurs on." msgstr "" "Utilice \"TODO\" para hacer que un evento siempre se produzca en la misma " "fecha. Si el evento es periódico, seleccione uno de los días en los que el " "evento sucede." #: add.c:519 msgid "Add an event" msgstr "Añadir un evento" #: edit.c:39 msgid "What is the new description of this event?\n" msgstr "¿Cuál es la descripción del nuevo evento?\n" #: edit.c:59 msgid "Editing the event:\n" msgstr "Editar este evento:\n" #: edit.c:67 msgid "Edit the event date (how often it happens, start date, end date)." msgstr "" "Editar la fecha del evento (con qué frecuencia ocurre, fecha de inicio, " "fecha de fin)." #: edit.c:69 msgid "Edit the event description." msgstr "Editar la descripción del evento." #: edit.c:71 msgid "Select action [1--2]: " msgstr "Seleccione acción [1--2]: " #: edit.c:103 msgid "Edit an event" msgstr "Editar un evento" #: del.c:47 del.c:55 del.c:88 msgid " The event was NOT deleted." msgstr " El evento NO ha sido eliminado." #: del.c:96 #, c-format msgid "Event removed from %s.\n" msgstr "Evento eliminado de %s.\n" #: del.c:99 #, c-format msgid "ERROR: Couldn't find event to be deleted in %s" msgstr "ERROR: No es posible encontrar el evento a eliminar en %s" #: del.c:110 msgid "Delete an event" msgstr "Eliminar un evento" #: del.c:114 msgid "" "If you want to delete old events that won't occur again, you can use pal's -" "x option instead of deleting the events manually." msgstr "" "Si desea eliminar eventos viejos que no ocurrirán de nuevo, puede usar la " "opción -x de pal en lugar de eliminarlos manualmente." #: del.c:120 msgid "You have selected to delete the following event:\n" msgstr "Ha seleccionado eliminar el siguiente evento:\n" #: del.c:123 msgid "Are you sure you want to delete this event? [y/n]: " msgstr "¿Está seguro de que desea eliminar este evento? [s/n]: " #: remind.c:45 msgid "Event reminder" msgstr "Aviso de evento" #: remind.c:49 msgid "" "This feature allows you to select one event and have an email sent to you " "about the event at a date/time that you provide. If the event is recurring, " "you will only receive one reminder. You MUST have atd, crond and sendmail " "installed and working for this feature to work." msgstr "" "Esta opción permite seleccionar un evento y especificar una fecha/hora a " "la que se enviará un aviso sobre el evento. Si el evento es recurrente, " "sólo recibirá un aviso. Para que esta opción funcione DEBE tener atd, crond " "o sendmail instalado y funcionando en su equipo." #: remind.c:78 msgid "Remind me on (HH:MM YYYY-MM-DD): " msgstr "Recordar en (HH:MM AAAA-MM-DD): " #: remind.c:83 msgid "Username on local machine or email address: " msgstr "Nombre de usuario en la máquina local o dirección de correo electrónico: " #: remind.c:101 msgid "Event: " msgstr "Evento: " #: remind.c:105 msgid "Event date: " msgstr "Fecha del evento: " #: remind.c:114 msgid "Event type: " msgstr "Tipo del evento: " #: remind.c:123 msgid "Attempting to run 'at'...\n" msgstr "Intentando ejecutar 'at'...\n" #: remind.c:128 msgid "" "ERROR: Date string was invalid or could not run 'at'. Is 'atd' running?" msgstr "" "ERROR: La fecha no es válida o no puso ejecutarse 'at'. ¿Está 'atd' en ejecución?" #: remind.c:132 msgid "Successfully added event to the 'at' queue.\n" msgstr "Evento añadido a la cola de 'at' con éxito.\n" #: search.c:106 #, c-format msgid "" "[ Begin search results: %s ]\n" "[ From %s to %s inclusive ]\n" "\n" msgstr "" "[ Comenzar búsqueda de resultados: %s ]\n" "[ De %s a %s inclusive ]\n" "\n" #: search.c:163 #, c-format msgid "[ End search results: %s ] [ %d %s found ]\n" msgstr "[ Fin de búsqueda: %s ] [ %d %s encontrados ]\n" #~ msgid "" #~ "ERROR: When using -s, use -r to specify the range to search within.\n" #~ msgstr "" #~ "ERROR: Si usa -s, use -r para especificar el rango en el que buscar.\n" #~ msgid "- Annually: On day %d of every %s\n" #~ msgstr "- Anual: El día %d de todos los %s\n" #~ msgid "Is this the date you want to add an event to?\n" #~ msgstr "¿Desea añadir el evento en esta fecha?\n" #~ msgid "" #~ "NOTE: Use \"today\" to edit a TODO item. If the event is recurring, " #~ "select one of the days the event occurs on." #~ msgstr "" #~ "NOTA: Use \"hoy\" para editar un item TODO. Si el evento es periódico, " #~ "seleccione uno de los días en los que el evento ocurre." #~ msgid "What is the number of the event you want to edit?\n" #~ msgstr "¿Cuál es el número del evento que desea editar?\n" #~ msgid "" #~ "You seleected an event in a global calendar file. pal will only allow " #~ "you to edit local calendar files.\n" #~ msgstr "" #~ "Ha seleccionado un evento en un archivo global de calendario. pal sólo le " #~ "permitirá editar archivos de calendario locales.\n" pal-0.4.3/po/tr.po0000644000175000017500000004105411043370327013575 0ustar kleptogkleptog# pal calendar, Turkish translation # # Copyright (C) 2006 Can Burak Çilingir # Add your name above, do not remove previous translators. # # This file is distributed under the same license as the pal package. # Scott Kuhl, 2004. # msgid "" msgstr "" "Project-Id-Version: pal 0.3.4\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2006-01-14 16:30+0200\n" "PO-Revision-Date: 2006-01-14 17:37+0200\n" "Last-Translator: Can Burak Çilingir \n" "Language-Team: Turkish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit" #: main.c:86 main.c:347 msgid "tomorrow" msgstr "yarın" #: main.c:92 main.c:347 msgid "yesterday" msgstr "dün" #: main.c:98 main.c:347 msgid "today" msgstr "bugün" #: main.c:104 msgid "mo" msgstr "pt" #: main.c:105 msgid "next mo" msgstr "ilk pt" #: main.c:111 msgid "tu" msgstr "sa" #: main.c:112 msgid "next tu" msgstr "ilk sa" #: main.c:118 msgid "we" msgstr "ça" #: main.c:119 msgid "next we" msgstr "ilk ça" #: main.c:125 msgid "th" msgstr "pe" #: main.c:126 msgid "next th" msgstr "ilk p" #: main.c:132 msgid "fr" msgstr "cu" #: main.c:133 msgid "next fr" msgstr "ilk cu" #: main.c:139 msgid "sa" msgstr "ct" #: main.c:140 msgid "next sa" msgstr "ilk ct" #: main.c:145 msgid "su" msgstr "pa" #: main.c:146 msgid "next su" msgstr "ilk pa" #: main.c:152 msgid "last mo" msgstr "son pt" #: main.c:158 msgid "last tu" msgstr "son sa" #: main.c:164 msgid "last we" msgstr "son ça" #: main.c:170 msgid "last th" msgstr "son pe" #: main.c:176 msgid "last fr" msgstr "son cu" #: main.c:182 msgid "last sa" msgstr "son ct" #: main.c:188 msgid "last su" msgstr "son pa" #: main.c:199 msgid "^[0-9]+ days away$" msgstr "^[0-9]+ gün var$" #: main.c:217 msgid "^[0-9]+ days ago$" msgstr "^[0-9]+ gün önce$" #: main.c:345 #, c-format msgid "ERROR: The following date is not valid: %s\n" msgstr "HATA: Geçersiz tarih: %s\n" #: main.c:346 msgid "Valid date formats include:" msgstr "Geçerli tarih biçimleri:" #: main.c:347 msgid "dd, mmdd, yyyymmdd," msgstr "gg, aagg, yyyyaagg," #: main.c:348 msgid "'n days away', 'n days ago'," msgstr "" #: main.c:349 msgid "first two letters of weekday," msgstr "" #: main.c:350 msgid "'next ' followed by first two letters of weekday," msgstr "" #: main.c:351 msgid "'last ' followed by first two letters of weekday," msgstr "" #: main.c:352 msgid "'1 Jan 2000', 'Jan 1 2000', etc." msgstr "" #: main.c:372 msgid "" "NOTE: You can use -r to specify the range of days to search. By default, " "pal searches days within one year of today." msgstr "" #: main.c:422 msgid "Copyright (C) 2004, Scott Kuhl" msgstr "" #: main.c:425 msgid "" "pal is licensed under the GNU General Public License and has NO WARRANTY." msgstr "" #: main.c:428 msgid "" " -d date Show events on the given date. Valid formats for date " "include: dd, mmdd, yyyymmdd, 'Jan 1 2000'. Run 'man pal' for a list of all " "valid formats." msgstr "" #: main.c:429 msgid "" " -r n Display events within n days after today or a date used with -" "d. (default: n=0, show nothing)" msgstr "" #: main.c:430 msgid "" " -r p-n Display events within p days before and n days after today or " "a date used with -d." msgstr "" #: main.c:431 msgid "" " -s regex Search for events matching the regular expression. Use -r to " "select range of days to search." msgstr "" #: main.c:432 msgid " -x n Expunge events that are n or more days old." msgstr "" #: main.c:434 msgid " -c n Display calendar with n lines. (default: 5)" msgstr "" #: main.c:435 msgid " -f file Load 'file' instead of ~/.pal/pal.conf" msgstr "" #: main.c:436 msgid " -u username Load /home/username/.pal/pal.conf" msgstr "" #: main.c:437 msgid "" " -p palfile Load *.pal file only (overrides files loaded from pal.conf)" msgstr "" #: main.c:438 msgid " -m Add/Modify/Delete events interactively." msgstr "" #: main.c:439 msgid " --color Force colors, regardless of terminal type." msgstr "" #: main.c:440 msgid " --nocolor Force no colors, regardless of terminal type." msgstr "" #: main.c:441 msgid " --mail Generate output readable by sendmail." msgstr "" #: main.c:442 msgid " --html Generate HTML calendar. Set size of calendar with -c." msgstr "" #: main.c:443 msgid " --latex Generate LaTeX calendar. Set size of calendar with -c." msgstr "" #: main.c:444 msgid " -v Verbose output." msgstr "" #: main.c:445 msgid " --version Display version information." msgstr "" #: main.c:446 msgid " -h, --help Display this help message." msgstr "" #: main.c:449 msgid "Type \"man pal\" for more information." msgstr "" #: main.c:464 msgid "ERROR: Number required after -r argument." msgstr "" #: main.c:465 main.c:490 main.c:502 main.c:579 main.c:596 main.c:611 #: main.c:628 main.c:642 main.c:651 msgid "Use --help for more information." msgstr "" #: main.c:489 msgid "ERROR: Number required after -c argument." msgstr "" #: main.c:501 msgid "ERROR: Date required after -d argument." msgstr "" #: main.c:509 msgid "NOTE: Use quotes around the date if it has spaces.\n" msgstr "" #: main.c:523 msgid "WARNING: -a is deprecated, use -m instead.\n" msgstr "" #: main.c:568 #, c-format msgid "Compiled with prefix: %s\n" msgstr "" #: main.c:578 msgid "ERROR: Pal conf file required after -f argument." msgstr "" #: main.c:595 msgid "ERROR: *.pal file required after -p argument." msgstr "" #: main.c:610 msgid "ERROR: Username required after -u argument." msgstr "" #: main.c:627 msgid "ERROR: Regular expression required after -s argument." msgstr "" #: main.c:641 msgid "ERROR: Number required after -x argument." msgstr "" #: main.c:650 msgid "ERROR: Bad argument:" msgstr "" #: main.c:827 msgid "Manage events" msgstr "Olayları düzenle" #: main.c:829 msgid "Press Control+c at any time to cancel.\n" msgstr "İptal etmek için istediÄŸiniz zaman Ctrl+c'ye basabilirsiniz.\n" #: main.c:834 msgid "Add an event." msgstr "Olay ekle." #: main.c:836 msgid "Edit an event." msgstr "Olay düzenle." #: main.c:838 msgid "Delete an event." msgstr "Olay sil." #: main.c:840 msgid "Remind me about an event (with at/cron)." msgstr "Olayı bana anımsat (at/cron vasıtasıyla)." #: main.c:842 msgid "Exit." msgstr "Çık." #: main.c:844 msgid "Select action [1--5]: " msgstr "İşlem seçin [1--5]: " #: output.c:327 msgid "Mo Tu We Th Fr Sa Su" msgstr "Pt Sa Ça Pe Cu Ct Pa" #: output.c:329 msgid "Su Mo Tu We Th Fr Sa" msgstr "Pa Pt Sa Ça Pe Cu Ct" #: output.c:583 msgid "Today" msgstr "Bugün" #: output.c:585 msgid "Tomorrow" msgstr "Yarın" #: output.c:587 msgid "Yesterday" msgstr "Dün" #: output.c:589 #, c-format msgid "%d days away" msgstr "%d gün sonra" #: output.c:591 #, c-format msgid "%d days ago" msgstr "%d gün önce" #: output.c:639 msgid "No events." msgstr "" #: input.c:188 #, c-format msgid "WARNING: File is missing 2 character marker and event type: %s\n" msgstr "" #: input.c:207 msgid "ERROR: First line is improperly formatted.\n" msgstr "" #: input.c:208 input.c:275 input.c:292 msgid "FILE" msgstr "" #: input.c:210 input.c:276 input.c:293 msgid "LINE" msgstr "" #: input.c:216 #, c-format msgid "ERROR: First line is not ASCII or UTF-8 in %s.\n" msgstr "" #: input.c:274 msgid "ERROR: Invalid date string.\n" msgstr "" #: input.c:291 msgid "ERROR: Event description missing.\n" msgstr "" #: input.c:306 #, c-format msgid "ERROR: Event text '%s' is not ASCII or UTF-8 in file %s.\n" msgstr "" #: input.c:339 msgid "Expunged" msgstr "" #: input.c:394 del.c:54 #, c-format msgid "ERROR: Can't write file: %s\n" msgstr "" #: input.c:395 #, c-format msgid "File will not be expunged: %s" msgstr "" #: input.c:446 del.c:87 #, c-format msgid "ERROR: Can't rename %s to %s\n" msgstr "" #: input.c:465 #, c-format msgid "ERROR: File doesn't exist: %s\n" msgstr "" #: input.c:488 #, c-format msgid "ERROR: Can't find file. I tried %s and %s.\n" msgstr "" #: input.c:511 #, c-format msgid "Reading: %s\n" msgstr "" #: input.c:514 del.c:46 #, c-format msgid "ERROR: Can't read file: %s\n" msgstr "" #: input.c:533 msgid "Looking for data to expunge.\n" msgstr "" #: input.c:542 #, c-format msgid "ERROR: Can't open file: %s\n" msgstr "" #: input.c:555 #, c-format msgid "NOTE: Creating %s\n" msgstr "" #: input.c:556 msgid "" "NOTE: Edit ~/.pal/pal.conf to change how and if certain events are " "displayed.\n" msgstr "" #: input.c:564 #, c-format msgid "ERROR: Can't create directory: %s\n" msgstr "" #: input.c:580 msgid "ERROR: Can't open file: /etc/pal.conf\n" msgstr "" #: input.c:581 msgid "ERROR: Can't open file: " msgstr "" #: input.c:581 msgid "/share/pal/pal.conf\n" msgstr "" #: input.c:582 msgid "ERROR: This indicates an improper installation.\n" msgstr "" #: input.c:589 #, c-format msgid "ERROR: Can't create/write file: %s\n" msgstr "" #: input.c:663 input.c:712 #, c-format msgid "ERROR: Invalid color '%s' in file %s." msgstr "" #: input.c:665 input.c:714 msgid "Valid colors:" msgstr "" #: input.c:737 #, c-format msgid "ERROR: Invalid line (File: %s, Line text: %s)\n" msgstr "" #: input.c:744 #, c-format msgid "" "Done reading data (%d events, %d files).\n" "\n" msgstr "" #: rl.c:69 msgid "WARNING: Failed to convert your input into UTF-8.\n" msgstr "" #: rl.c:75 msgid "Converted string to UTF-8." msgstr "" #: rl.c:93 rl.c:96 msgid "y" msgstr "e" #: rl.c:94 msgid "n" msgstr "h" #: rl.c:130 msgid "Use \"today\" to access TODO events." msgstr "TODO olaylarına eriÅŸmek için \"today\" yazın." #: rl.c:133 rl.c:238 msgid "" "Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away" msgstr "" #: rl.c:135 msgid "Date for event or search string: " msgstr "" #: rl.c:156 rl.c:190 msgid "Use \"0\" to use a different date or search string." msgstr "" #: rl.c:158 rl.c:192 msgid "Select event number: " msgstr "" #: rl.c:172 rl.c:206 msgid "" "This event is in a global calendar file. You can change this event only by " "editing the global calendar file manually (root access might be required)." msgstr "" #: rl.c:240 msgid "Date for event: " msgstr "" #: rl.c:250 msgid "Events on the date you selected:\n" msgstr "" #: rl.c:257 msgid "Is this the correct date?" msgstr "" #: rl.c:260 msgid "%a %e %b %Y - Accept? [y/n]: " msgstr "" #: html.c:66 html.c:76 latex.c:75 latex.c:85 msgid "Sunday" msgstr "" #: html.c:68 latex.c:77 msgid "Monday" msgstr "" #: html.c:69 latex.c:78 msgid "Tuesday" msgstr "" #: html.c:70 latex.c:79 msgid "Wednesday" msgstr "" #: html.c:71 latex.c:80 msgid "Thursday" msgstr "" #: html.c:72 latex.c:81 msgid "Friday" msgstr "" #: html.c:73 latex.c:82 msgid "Saturday" msgstr "" #: add.c:36 msgid "1st" msgstr "" #: add.c:37 msgid "2nd" msgstr "" #: add.c:38 msgid "3rd" msgstr "" #: add.c:39 msgid "4th" msgstr "" #: add.c:40 msgid "5th" msgstr "" #: add.c:41 msgid "6th" msgstr "" #: add.c:42 msgid "7th" msgstr "" #: add.c:43 msgid "8th" msgstr "" #: add.c:44 msgid "9th" msgstr "" #: add.c:45 msgid "10th" msgstr "" #: add.c:56 msgid "Does this event have starting and ending dates? " msgstr "" #: add.c:58 add.c:129 msgid "[y/n]: " msgstr "" #: add.c:76 add.c:98 msgid "Start date: " msgstr "" #: add.c:83 add.c:100 msgid "End date: " msgstr "" #: add.c:90 msgid "ERROR: The end date is the same as or before the start date.\n" msgstr "" #: add.c:102 msgid "Accept? [y/n]:" msgstr "" #: add.c:125 msgid "Is the event recurring? " msgstr "" #: add.c:138 msgid "Select how often this event occurs\n" msgstr "" #: add.c:141 msgid "- Daily\n" msgstr "" #: add.c:145 #, c-format msgid "- Weekly: Every %s\n" msgstr "" #: add.c:148 #, c-format msgid "- Monthly: Day %d of every month\n" msgstr "" #: add.c:154 #, c-format msgid "- Monthly: The %s %s of every month\n" msgstr "" #: add.c:159 #, c-format msgid "- Annually: %d %s\n" msgstr "" #: add.c:166 #, c-format msgid "- Annually: The %s %s of every %s\n" msgstr "" #: add.c:176 #, c-format msgid "- Monthly: The last %s of every month\n" msgstr "" #: add.c:181 #, c-format msgid "- Annually: The last %s in %s\n" msgstr "" #: add.c:189 msgid "Select type [1--8]: " msgstr "" #: add.c:191 msgid "Select type [1--6]: " msgstr "" #: add.c:323 msgid "What is the description of this event?\n" msgstr "" #: add.c:332 edit.c:48 msgid "Description: " msgstr "" #: add.c:335 edit.c:51 msgid "Is this description correct? [y/n]: " msgstr "" #: add.c:348 msgid "Calendar file (usually ending with \".pal\") to add event to:\n" msgstr "Olayın ekleneceÄŸi takvim dosyası (genelde \".pal\" ile biter):\n" #: add.c:383 #, c-format msgid "ERROR: %s is a directory.\n" msgstr "" #: add.c:390 #, c-format msgid "WARNING: %s does not exist.\n" msgstr "" #: add.c:392 msgid "Create? [y/n]: " msgstr "" #: add.c:400 #, c-format msgid "ERROR: Can't create %s.\n" msgstr "" #: add.c:411 #, c-format msgid "Information for %s:\n" msgstr "" #: add.c:413 msgid "2 character marker for calendar: " msgstr "" #: add.c:416 msgid "Calendar title: " msgstr "" #: add.c:422 msgid "" "If you want events in this new calendar file to appear when you run pal,\n" " you need to manually update ~/.pal/pal.conf" msgstr "" #: add.c:456 #, c-format msgid "ERROR: Can't read from file %s.\n" msgstr "" #: add.c:457 add.c:474 msgid "Try again? [y/n]: " msgstr "" #: add.c:473 #, c-format msgid "ERROR: Can't write to file %s.\n" msgstr "" #: add.c:487 #, c-format msgid "Wrote new event \"%s %s\" to %s.\n" msgstr "" #: add.c:500 msgid "" "Use \"TODO\" to make an event that always occurs on the current date. If " "the event is recurring, select one of the days the event occurs on." msgstr "" #: add.c:519 msgid "Add an event" msgstr "Olay ekle" #: edit.c:39 msgid "What is the new description of this event?\n" msgstr "" #: edit.c:59 msgid "Editing the event:\n" msgstr "" #: edit.c:67 msgid "Edit the event date (how often it happens, start date, end date)." msgstr "" #: edit.c:69 msgid "Edit the event description." msgstr "" #: edit.c:71 msgid "Select action [1--2]: " msgstr "" #: edit.c:103 msgid "Edit an event" msgstr "Olay düzenle" #: del.c:47 del.c:55 del.c:88 msgid " The event was NOT deleted." msgstr "" #: del.c:96 #, c-format msgid "Event removed from %s.\n" msgstr "" #: del.c:99 #, c-format msgid "ERROR: Couldn't find event to be deleted in %s" msgstr "" #: del.c:110 msgid "Delete an event" msgstr "Olay sil" #: del.c:114 msgid "" "If you want to delete old events that won't occur again, you can use pal's -" "x option instead of deleting the events manually." msgstr "" #: del.c:120 msgid "You have selected to delete the following event:\n" msgstr "" #: del.c:123 msgid "Are you sure you want to delete this event? [y/n]: " msgstr "" #: remind.c:64 msgid "Event reminder" msgstr "" #: remind.c:68 msgid "" "This feature allows you to select one event and have an email sent to you " "about the event at a date/time that you provide. If the event is recurring, " "you will only receive one reminder. You MUST have atd, crond and sendmail " "installed and working for this feature to work." msgstr "" #: remind.c:97 msgid "Remind me on (HH:MM YYYY-MM-DD): " msgstr "" #: remind.c:102 msgid "Username on local machine or email address: " msgstr "" #: remind.c:123 msgid "Event: " msgstr "" #: remind.c:127 msgid "Event date: " msgstr "" #: remind.c:136 msgid "Event type: " msgstr "" #: remind.c:145 msgid "Attempting to run 'at'...\n" msgstr "" #: remind.c:150 msgid "" "ERROR: Date string was invalid or could not run 'at'. Is 'atd' running?" msgstr "" #: remind.c:154 msgid "Successfully added event to the 'at' queue.\n" msgstr "" #: search.c:106 #, c-format msgid "" "[ Begin search results: %s ]\n" "[ From %s to %s inclusive ]\n" "\n" msgstr "" #: search.c:163 #, c-format msgid "[ End search results: %s ] [ %d %s found ]\n" msgstr "" pal-0.4.3/po/pal.pot0000644000175000017500000004101311043370327014103 0ustar kleptogkleptog# pal calendar # Copyright (C) 2005 Scott Kuhl # This file is distributed under the same license as the pal package. # Scott Kuhl, 2005. # #, fuzzy msgid "" msgstr "" "Project-Id-Version: pal 0.4.3\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2008-07-28 18:16+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" #: main.c:87 main.c:348 msgid "tomorrow" msgstr "" #: main.c:93 main.c:348 msgid "yesterday" msgstr "" #: main.c:99 main.c:348 msgid "today" msgstr "" #: main.c:105 msgid "mo" msgstr "" #: main.c:106 msgid "next mo" msgstr "" #: main.c:112 msgid "tu" msgstr "" #: main.c:113 msgid "next tu" msgstr "" #: main.c:119 msgid "we" msgstr "" #: main.c:120 msgid "next we" msgstr "" #: main.c:126 msgid "th" msgstr "" #: main.c:127 msgid "next th" msgstr "" #: main.c:133 msgid "fr" msgstr "" #: main.c:134 msgid "next fr" msgstr "" #: main.c:140 msgid "sa" msgstr "" #: main.c:141 msgid "next sa" msgstr "" #: main.c:146 msgid "su" msgstr "" #: main.c:147 msgid "next su" msgstr "" #: main.c:153 msgid "last mo" msgstr "" #: main.c:159 msgid "last tu" msgstr "" #: main.c:165 msgid "last we" msgstr "" #: main.c:171 msgid "last th" msgstr "" #: main.c:177 msgid "last fr" msgstr "" #: main.c:183 msgid "last sa" msgstr "" #: main.c:189 msgid "last su" msgstr "" #: main.c:200 msgid "^[0-9]+ days away$" msgstr "" #: main.c:218 msgid "^[0-9]+ days ago$" msgstr "" #: main.c:346 #, c-format msgid "ERROR: The following date is not valid: %s\n" msgstr "" #: main.c:347 msgid "Valid date formats include:" msgstr "" #: main.c:348 msgid "dd, mmdd, yyyymmdd," msgstr "" #: main.c:349 msgid "'n days away', 'n days ago'," msgstr "" #: main.c:350 msgid "first two letters of weekday," msgstr "" #: main.c:351 msgid "'next ' followed by first two letters of weekday," msgstr "" #: main.c:352 msgid "'last ' followed by first two letters of weekday," msgstr "" #: main.c:353 msgid "'1 Jan 2000', 'Jan 1 2000', etc." msgstr "" #: main.c:373 msgid "" "NOTE: You can use -r to specify the range of days to search. By default, " "pal searches days within one year of today." msgstr "" #: main.c:424 msgid "Copyright (C) 2006, Scott Kuhl" msgstr "" #: main.c:427 msgid "" "pal is licensed under the GNU General Public License and has NO WARRANTY." msgstr "" #: main.c:430 msgid "" " -d date Show events on the given date. Valid formats for date " "include: dd, mmdd, yyyymmdd, 'Jan 1 2000'. Run 'man pal' for a list of all " "valid formats." msgstr "" #: main.c:431 msgid "" " -r n Display events within n days after today or a date used with -" "d. (default: n=0, show nothing)" msgstr "" #: main.c:432 msgid "" " -r p-n Display events within p days before and n days after today or " "a date used with -d." msgstr "" #: main.c:433 msgid "" " -s regex Search for events matching the regular expression. Use -r to " "select range of days to search." msgstr "" #: main.c:434 msgid " -x n Expunge events that are n or more days old." msgstr "" #: main.c:436 msgid " -c n Display calendar with n lines. (default: 5)" msgstr "" #: main.c:437 msgid " -f file Load 'file' instead of ~/.pal/pal.conf" msgstr "" #: main.c:438 msgid " -u username Load /home/username/.pal/pal.conf" msgstr "" #: main.c:439 msgid "" " -p palfile Load *.pal file only (overrides files loaded from pal.conf)" msgstr "" #: main.c:440 msgid " -m Add/Modify/Delete events interactively." msgstr "" #: main.c:441 msgid " --color Force colors, regardless of terminal type." msgstr "" #: main.c:442 msgid " --nocolor Force no colors, regardless of terminal type." msgstr "" #: main.c:443 msgid " --mail Generate output readable by sendmail." msgstr "" #: main.c:444 msgid " --html Generate HTML calendar. Set size of calendar with -c." msgstr "" #: main.c:445 msgid " --latex Generate LaTeX calendar. Set size of calendar with -c." msgstr "" #: main.c:446 msgid " -v Verbose output." msgstr "" #: main.c:447 msgid " --version Display version information." msgstr "" #: main.c:448 msgid " -h, --help Display this help message." msgstr "" #: main.c:451 msgid "Type \"man pal\" for more information." msgstr "" #: main.c:466 msgid "ERROR: Number required after -r argument." msgstr "" #: main.c:467 main.c:492 main.c:504 main.c:583 main.c:600 main.c:615 #: main.c:632 main.c:646 main.c:655 msgid "Use --help for more information." msgstr "" #: main.c:491 msgid "ERROR: Number required after -c argument." msgstr "" #: main.c:503 msgid "ERROR: Date required after -d argument." msgstr "" #: main.c:513 msgid "NOTE: Use quotes around the date if it has spaces.\n" msgstr "" #: main.c:527 msgid "WARNING: -a is deprecated, use -m instead.\n" msgstr "" #: main.c:572 #, c-format msgid "Compiled with prefix: %s\n" msgstr "" #: main.c:582 msgid "ERROR: Pal conf file required after -f argument." msgstr "" #: main.c:599 msgid "ERROR: *.pal file required after -p argument." msgstr "" #: main.c:614 msgid "ERROR: Username required after -u argument." msgstr "" #: main.c:631 msgid "ERROR: Regular expression required after -s argument." msgstr "" #: main.c:645 msgid "ERROR: Number required after -x argument." msgstr "" #: main.c:654 msgid "ERROR: Bad argument:" msgstr "" #: output.c:327 msgid "Mo Tu We Th Fr Sa Su" msgstr "" #: output.c:329 msgid "Su Mo Tu We Th Fr Sa" msgstr "" #: output.c:562 msgid "Today" msgstr "" #: output.c:564 msgid "Tomorrow" msgstr "" #: output.c:566 msgid "Yesterday" msgstr "" #: output.c:568 #, c-format msgid "%d days away" msgstr "" #: output.c:570 #, c-format msgid "%d days ago" msgstr "" #: output.c:617 output.c:623 msgid "No events." msgstr "" #: input.c:189 #, c-format msgid "WARNING: File is missing 2 character marker and event type: %s\n" msgstr "" #: input.c:210 msgid "ERROR: First line is improperly formatted.\n" msgstr "" #: input.c:211 input.c:276 input.c:294 input.c:321 msgid "FILE" msgstr "" #: input.c:213 input.c:277 input.c:295 input.c:322 msgid "LINE" msgstr "" #: input.c:220 #, c-format msgid "ERROR: First line is not ASCII or UTF-8 in %s.\n" msgstr "" #: input.c:275 msgid "ERROR: Invalid date string.\n" msgstr "" #: input.c:293 msgid "ERROR: Event description missing.\n" msgstr "" #: input.c:309 #, c-format msgid "ERROR: Event text '%s' is not ASCII or UTF-8 in file %s.\n" msgstr "" #: input.c:320 msgid "ERROR: Event with count has no start date\n" msgstr "" #: input.c:336 msgid "Expunged" msgstr "" #: input.c:391 del.c:54 #, c-format msgid "ERROR: Can't write file: %s\n" msgstr "" #: input.c:392 #, c-format msgid "File will not be expunged: %s" msgstr "" #: input.c:442 del.c:87 #, c-format msgid "ERROR: Can't rename %s to %s\n" msgstr "" #: input.c:462 #, c-format msgid "ERROR: File doesn't exist: %s\n" msgstr "" #: input.c:486 #, c-format msgid "ERROR: Can't find file. I tried %s and %s.\n" msgstr "" #: input.c:512 #, c-format msgid "Reading: %s\n" msgstr "" #: input.c:515 del.c:46 #, c-format msgid "ERROR: Can't read file: %s\n" msgstr "" #: input.c:534 msgid "Looking for data to expunge.\n" msgstr "" #: input.c:543 #, c-format msgid "ERROR: Can't open file: %s\n" msgstr "" #: input.c:556 #, c-format msgid "NOTE: Creating %s\n" msgstr "" #: input.c:557 msgid "" "NOTE: Edit ~/.pal/pal.conf to change how and if certain events are " "displayed.\n" msgstr "" #: input.c:565 #, c-format msgid "ERROR: Can't create directory: %s\n" msgstr "" #: input.c:581 msgid "ERROR: Can't open file: /etc/pal.conf\n" msgstr "" #: input.c:582 msgid "ERROR: Can't open file: " msgstr "" #: input.c:583 msgid "ERROR: This indicates an improper installation.\n" msgstr "" #: input.c:590 #, c-format msgid "ERROR: Can't create/write file: %s\n" msgstr "" #: input.c:664 input.c:715 #, c-format msgid "ERROR: Invalid color '%s' in file %s." msgstr "" #: input.c:666 input.c:717 msgid "Valid colors:" msgstr "" #: input.c:740 #, c-format msgid "ERROR: Invalid line (File: %s, Line text: %s)\n" msgstr "" #: input.c:747 #, c-format msgid "" "Done reading data (%d events, %d files).\n" "\n" msgstr "" #: rl.c:99 msgid "WARNING: Failed to convert your input into UTF-8.\n" msgstr "" #: rl.c:105 msgid "Converted string to UTF-8." msgstr "" #: rl.c:224 msgid "y" msgstr "" #: rl.c:229 msgid "n" msgstr "" #: rl.c:252 msgid "Use \"today\" to access TODO events." msgstr "" #: rl.c:255 rl.c:362 msgid "" "Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away" msgstr "" #: rl.c:257 msgid "Date for event or search string: " msgstr "" #: rl.c:278 rl.c:312 msgid "Use \"0\" to use a different date or search string." msgstr "" #: rl.c:280 rl.c:314 msgid "Select event number: " msgstr "" #: rl.c:294 rl.c:328 msgid "" "This event is in a global calendar file. You can change this event only by " "editing the global calendar file manually (root access might be required)." msgstr "" #: rl.c:364 msgid "Date for event: " msgstr "" #: rl.c:374 msgid "Events on the date you selected:\n" msgstr "" #: rl.c:381 msgid "Is this the correct date?" msgstr "" #: rl.c:384 msgid "%a %e %b %Y - Accept? [y/n]: " msgstr "" #: html.c:70 html.c:80 latex.c:79 latex.c:89 msgid "Sunday" msgstr "" #: html.c:72 latex.c:81 msgid "Monday" msgstr "" #: html.c:73 latex.c:82 msgid "Tuesday" msgstr "" #: html.c:74 latex.c:83 msgid "Wednesday" msgstr "" #: html.c:75 latex.c:84 msgid "Thursday" msgstr "" #: html.c:76 latex.c:85 msgid "Friday" msgstr "" #: html.c:77 latex.c:86 msgid "Saturday" msgstr "" #: html.c:245 msgid "Calendar created with pal." msgstr "" #: add.c:35 msgid "1st" msgstr "" #: add.c:36 msgid "2nd" msgstr "" #: add.c:37 msgid "3rd" msgstr "" #: add.c:38 msgid "4th" msgstr "" #: add.c:39 msgid "5th" msgstr "" #: add.c:40 msgid "6th" msgstr "" #: add.c:41 msgid "7th" msgstr "" #: add.c:42 msgid "8th" msgstr "" #: add.c:43 msgid "9th" msgstr "" #: add.c:44 msgid "10th" msgstr "" #: add.c:63 msgid "Does the event have start and end dates? " msgstr "" #: add.c:65 msgid "[y/n]: " msgstr "" #: add.c:99 add.c:105 add.c:147 manage.c:158 msgid "Start date: " msgstr "" #: add.c:117 msgid "End date (blank is none): " msgstr "" #: add.c:133 msgid "ERROR: End date must be after start date.\n" msgstr "" #: add.c:151 msgid "End date: " msgstr "" #: add.c:154 msgid "Accept? [y/n]:" msgstr "" #: add.c:180 msgid "Select how often this event occurs\n" msgstr "" #: add.c:206 msgid "Select type: " msgstr "" #: add.c:228 remind.c:143 msgid "Event type: " msgstr "" #: add.c:250 msgid "What is the description of the event?\n" msgstr "" #: add.c:267 add.c:270 msgid "Description: " msgstr "" #: add.c:275 msgid "Is this description correct? [y/n]: " msgstr "" #: add.c:289 msgid "Calendar file (usually ending with \".pal\") to add event to:\n" msgstr "" #: add.c:300 msgid "Filename: " msgstr "" #: add.c:321 #, c-format msgid "ERROR: %s is a directory.\n" msgstr "" #: add.c:332 #, c-format msgid "WARNING: %s does not exist.\n" msgstr "" #: add.c:334 msgid "Create? [y/n]: " msgstr "" #: add.c:347 #, c-format msgid "ERROR: Can't create %s.\n" msgstr "" #: add.c:360 #, c-format msgid "Information for %s:\n" msgstr "" #: add.c:363 msgid "2 character marker for calendar: " msgstr "" #: add.c:368 msgid "Calendar title: " msgstr "" #: add.c:374 msgid "" "If you want events in this new calendar file to appear when you run pal,\n" " you need to manually update ~/.pal/pal.conf" msgstr "" #: add.c:375 msgid "Press any key to continue." msgstr "" #: add.c:412 #, c-format msgid "ERROR: Can't read from file %s.\n" msgstr "" #: add.c:413 add.c:430 msgid "Try again? [y/n]: " msgstr "" #: add.c:429 #, c-format msgid "ERROR: Can't write to file %s.\n" msgstr "" #: add.c:443 #, c-format msgid "Wrote new event \"%s %s\" to %s.\n" msgstr "" #: add.c:466 msgid "Add an event" msgstr "" #: add.c:469 msgid "Selected date: " msgstr "" #: add.c:480 msgid "Date (in pal's format):" msgstr "" #: edit.c:63 edit.c:72 edit.c:80 edit.c:89 msgid "None" msgstr "" #: edit.c:120 msgid "Event Description" msgstr "" #: edit.c:121 msgid "Event Type" msgstr "" #: edit.c:122 msgid "Skip Count" msgstr "" #: edit.c:123 msgid "Start Date" msgstr "" #: edit.c:124 msgid "End Date" msgstr "" #: edit.c:125 msgid "Start Time" msgstr "" #: edit.c:126 msgid "End Time" msgstr "" #: edit.c:127 msgid "Hashtable Key" msgstr "" #: edit.c:128 msgid "Date in File" msgstr "" #: edit.c:129 msgid "Event File" msgstr "" #: edit.c:130 msgid "Event Marked on Calendar?" msgstr "" #: edit.c:131 msgid "File Color" msgstr "" #: del.c:47 del.c:55 del.c:88 msgid " The event was NOT deleted." msgstr "" #: del.c:96 #, c-format msgid "Event removed from %s.\n" msgstr "" #: del.c:99 #, c-format msgid "ERROR: Couldn't find event to be deleted in %s" msgstr "" #: del.c:111 msgid "Delete an event" msgstr "" #: del.c:115 msgid "" "If you want to delete old events that won't occur again, you can use pal's -" "x option instead of deleting the events manually." msgstr "" #: del.c:121 msgid "You have selected to delete the following event:\n" msgstr "" #: del.c:124 manage.c:618 msgid "Are you sure you want to delete this event? [y/n]: " msgstr "" #: remind.c:63 msgid "Event reminder" msgstr "" #: remind.c:67 msgid "" "This feature allows you to select one event and have an email sent to you " "about the event at a date/time that you provide. If the event is recurring, " "you will only receive one reminder. You MUST have atd, crond and sendmail " "installed and working for this feature to work." msgstr "" #: remind.c:97 remind.c:101 msgid "Remind me on (HH:MM YYYY-MM-DD): " msgstr "" #: remind.c:106 remind.c:110 msgid "Username on local machine or email address: " msgstr "" #: remind.c:130 msgid "Event: " msgstr "" #: remind.c:134 msgid "Event date: " msgstr "" #: remind.c:152 msgid "Attempting to run 'at'...\n" msgstr "" #: remind.c:157 msgid "" "ERROR: Date string was invalid or could not run 'at'. Is 'atd' running?" msgstr "" #: remind.c:161 msgid "Successfully added event to the 'at' queue.\n" msgstr "" #: search.c:104 #, c-format msgid "" "[ Begin search results: %s ]\n" "[ From %s to %s inclusive ]\n" "\n" msgstr "" #: search.c:161 #, c-format msgid "[ End search results: %s ]" msgstr "" #: search.c:162 #, c-format msgid "[ %d event found ]\n" msgid_plural "[ %d events found ]\n" msgstr[0] "" msgstr[1] "" #: manage.c:150 msgid "Event Type: " msgstr "" #: manage.c:155 msgid "Skip count: " msgstr "" #: manage.c:166 msgid "End date: " msgstr "" #: manage.c:174 msgid "Key: " msgstr "" #: manage.c:274 #, c-format msgid "%s Isearch starting from %s" msgstr "" #: manage.c:275 msgid "Forward" msgstr "" #: manage.c:275 msgid "Backward" msgstr "" #: manage.c:283 msgid "No matches found!" msgstr "" #: manage.c:319 msgid "Isearch: " msgstr "" #: manage.c:400 msgid "pal calendar" msgstr "" #: manage.c:450 msgid "Press 'h' for help, 'q' to quit." msgstr "" #: manage.c:518 msgid "Goto date: " msgstr "" #: manage.c:562 msgid "Can't edit global event!" msgstr "" #: manage.c:567 msgid "New description: " msgstr "" #: manage.c:584 msgid "No event selected." msgstr "" #: manage.c:615 msgid "Can't delete global event!" msgstr "" #: manage.c:650 msgid "LeftArrow" msgstr "" #: manage.c:651 msgid "Back one day" msgstr "" #: manage.c:653 msgid "RightArrow" msgstr "" #: manage.c:654 msgid "Forward one day" msgstr "" #: manage.c:656 msgid "UpArrow" msgstr "" #: manage.c:657 msgid "Back one week or event (if in event selection mode)" msgstr "" #: manage.c:659 msgid "DownArrow" msgstr "" #: manage.c:660 msgid "Forward one week or event (if in event selection mode)" msgstr "" #: manage.c:663 msgid "This help screen." msgstr "" #: manage.c:666 msgid "Quit" msgstr "" #: manage.c:668 msgid "Tab, Enter" msgstr "" #: manage.c:669 msgid "Toggle event selection" msgstr "" #: manage.c:672 msgid "Jump to a specific date." msgstr "" #: manage.c:675 msgid "Jump to today." msgstr "" #: manage.c:678 msgid "Edit description of the selected event." msgstr "" #: manage.c:681 msgid "Add an event to the selected date." msgstr "" #: manage.c:684 msgid "Forward/reverse i-search" msgstr "" #: manage.c:686 msgid "Delete" msgstr "" #: manage.c:687 msgid "Delete selected event." msgstr "" #: manage.c:692 msgid "Edit date for selected event." msgstr "" #: manage.c:693 msgid "Search for event." msgstr "" #: manage.c:694 msgid "Remind me about an event." msgstr "" #: manage.c:697 msgid "Press any key to exit help." msgstr "" pal-0.4.3/po/pl.po0000644000175000017500000005655711043370327013601 0ustar kleptogkleptog# Copyright (C) 2004 Artur Gajda # This file is distributed under the same license as the pal package. # Scott Kuhl, 2004. # msgid "" msgstr "" "Project-Id-Version: pal 0.3.4_pre4\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2004-04-29 00:05+0200\n" "PO-Revision-Date: 2004-04-14 17:30+0200\n" "Last-Translator: Artur Gajda \n" "Language-Team: Polish pl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #: main.c:86 main.c:347 msgid "tomorrow" msgstr "jutro" #: main.c:92 main.c:347 msgid "yesterday" msgstr "wczoraj" #: main.c:98 main.c:347 msgid "today" msgstr "dzisiaj" #: main.c:104 msgid "mo" msgstr "Pn" #: main.c:105 msgid "next mo" msgstr "nastÄ™pny pn" #: main.c:111 msgid "tu" msgstr "wt" #: main.c:112 msgid "next tu" msgstr "nastÄ™pny wt" #: main.c:118 msgid "we" msgstr "Å›r" #: main.c:119 msgid "next we" msgstr "nastÄ™pna Å›r" #: main.c:125 msgid "th" msgstr "cz" #: main.c:126 msgid "next th" msgstr "nastÄ™pny cz" #: main.c:132 msgid "fr" msgstr "pi" #: main.c:133 msgid "next fr" msgstr "nastÄ™pny pi" #: main.c:139 msgid "sa" msgstr "so" #: main.c:140 msgid "next sa" msgstr "nastÄ™pna so" #: main.c:145 msgid "su" msgstr "ni" #: main.c:146 msgid "next su" msgstr "nastÄ™pna ni" #: main.c:152 msgid "last mo" msgstr "poprzedni pn" #: main.c:158 msgid "last tu" msgstr "poprzedni wt" #: main.c:164 msgid "last we" msgstr "poprzednia Å›r" #: main.c:170 msgid "last th" msgstr "poprzedni cz" #: main.c:176 msgid "last fr" msgstr "poprzedni pi" #: main.c:182 msgid "last sa" msgstr "poprzednia so" #: main.c:188 msgid "last su" msgstr "poprzednia ni" #: main.c:199 msgid "^[0-9]+ days away$" msgstr "za [0-9]+ dni$" #: main.c:217 msgid "^[0-9]+ days ago$" msgstr "^[0-9]+ dni wczeÅ›niej$" #: main.c:345 #, c-format msgid "ERROR: The following date is not valid: %s\n" msgstr "ERROR: Podana data nie jest poprawna: %s\n" #: main.c:346 msgid "Valid date formats include:" msgstr "Format poprawnej daty zawiera:" #: main.c:347 msgid "dd, mmdd, yyyymmdd," msgstr "dd, mmdd, rrrrmmdd," #: main.c:348 msgid "'n days away', 'n days ago'," msgstr "'za n dni', 'n dni wczeÅ›niej'," #: main.c:349 msgid "first two letters of weekday," msgstr "pierwsze dwie litery dnia tygodnia," #: main.c:350 msgid "'next ' followed by first two letters of weekday," msgstr "'nastÄ™pny ' wraz z pierwszymi dwoma literkami z nazwy dnia tygodnia," #: main.c:351 msgid "'last ' followed by first two letters of weekday," msgstr "'ostatni ' wraz z pierwszymi dwoma literkami z nazwy dnia tygodnia," #: main.c:352 msgid "'1 Jan 2000', 'Jan 1 2000', etc." msgstr "'1 Jan 2000', 'Jan 1 2000', itp." #: main.c:372 msgid "" "NOTE: You can use -r to specify the range of days to search. By default, " "pal searches days within one year of today." msgstr "INFO: Możesz użyć -r w celu okreÅ›lenia zasiÄ™gu dni do wyszukania. DomyÅ›lnie, pal szuka rok dni od dzisiaj" #: main.c:422 msgid "Copyright (C) 2004, Scott Kuhl" msgstr "" #: main.c:425 msgid "" "pal is licensed under the GNU General Public License and has NO WARRANTY." msgstr "" #: main.c:428 msgid "" " -d date Show events on the given date. Valid formats for date " "include: dd, mmdd, yyyymmdd, 'Jan 1 2000'. Run 'man pal' for a list of all " "valid formats." msgstr " -d data WyÅ›wietla wydarzenia o podanej dacie. Poprawne formaty daty: dd mmdd, rrrrmmdd, 'Jan 1 2000'. Uruchom 'man pal' w celu uzyskania peÅ‚nej listy" #: main.c:429 msgid "" " -r n Display events within n days after today or a date used with -" "d. (default: n=0, show nothing)" msgstr " -r n WyÅ›wietla wydarzenia w przeciÄ…gu n dni od dziÅ› lub podanej daty wraz z -d. (domyÅ›lnie: n=0, nic nie pokazuje)" #: main.c:430 msgid "" " -r p-n Display events within p days before and n days after today or " "a date used with -d." msgstr " -r p-n WyÅ›wietla wydarzenia od p dni wczeÅ›niej i n dni od dziÅ› lub podanej daty wraz z -d." #: main.c:431 msgid "" " -s regex Search for events matching the regular expression. Use -r to " "select range of days to search." msgstr " -s regex Szukaj wydarzeÅ„ pasujÄ…cych do podanego wyrażenia regularnego. Użyj -r w celu okreÅ›lenia ile dni w przód należy szukać." #: main.c:432 msgid " -x n Expunge events that are n or more days old." msgstr " -x n Wyczyść wydarzenia które sÄ… starsze o n lub wiÄ™cej dni." #: main.c:434 msgid " -c n Display calendar with n lines. (default: 5)" msgstr " -c n WyÅ›wietl kalendarz używajÄ…c n wierszy. (domyÅ›lnie: 5)" #: main.c:435 msgid " -f file Load 'file' instead of ~/.pal/pal.conf" msgstr " -f plik ZaÅ‚aduj 'plik' zamiast ~/.pal/pal.conf" #: main.c:436 msgid " -u username Load /home/username/.pal/pal.conf" msgstr " -u nazwa_użytkownika ZaÅ‚aduj /home/nazwa_użytkownika/.pal/pal.conf" #: main.c:437 msgid "" " -p palfile Load *.pal file only (overrides files loaded from pal.conf)" msgstr " -p plikpal ZaÅ‚aduj tylko pliki *.pal (ignoruje pliki Å‚adowane z pal.conf)" #: main.c:438 msgid " -m Add/Modify/Delete events interactively." msgstr " -m Dodaj/Modyfikuj/UsuÅ„ zdarzenia interaktywnie." #: main.c:439 msgid " --color Force colors, regardless of terminal type." msgstr " --color WymuÅ› używanie kolorów, niezależnie od typu terminala" #: main.c:440 msgid " --nocolor Force no colors, regardless of terminal type." msgstr " --nocolor WymuÅ› nie używanie kolorów, niezależnie od typu terminala" #: main.c:441 msgid " --mail Generate output readable by sendmail." msgstr " --mail Stwórz wynik możliwy do odczytania przez program sendmail." #: main.c:442 msgid " --html Generate HTML calendar. Set size of calendar with -c." msgstr " --html Stwórz kalendarz w formacie HTML. Rozmiar kalendarza ustaw przy pomocy -c." #: main.c:443 msgid " --latex Generate LaTeX calendar. Set size of calendar with -c." msgstr " --latex Stwórz kalendarz w formacie LaTeX Rozmiar kalendarza ustaw przy pomocy -c." #: main.c:444 msgid " -v Verbose output." msgstr " -v Włącz tryb gadatliwy." #: main.c:445 msgid " --version Display version information." msgstr " --version WyÅ›wietl informacjÄ™ o wersji programu." #: main.c:446 msgid " -h, --help Display this help message." msgstr " -h, --help WyÅ›wietl tÄ… pomoc." #: main.c:449 msgid "Type \"man pal\" for more information." msgstr "Wpisz \"man pal\" w celu uzyskania dalszych informacji." #: main.c:464 msgid "ERROR: Number required after -r argument." msgstr "BÅÄ„D: Wymagana liczba po argumencie -r." #: main.c:465 main.c:490 main.c:502 main.c:579 main.c:596 main.c:611 #: main.c:628 main.c:642 main.c:651 msgid "Use --help for more information." msgstr "Użyj --help w celu uzyskania dalszych informacji." #: main.c:489 msgid "ERROR: Number required after -c argument." msgstr "BÅÄ„D: Wymagana liczba po argumencie -c." #: main.c:501 msgid "ERROR: Date required after -d argument." msgstr "BÅÄ„D: Wymagana data po argumencie -d." #: main.c:509 msgid "NOTE: Use quotes around the date if it has spaces.\n" msgstr "INFO: Date wpisz pomiÄ™dzy cudzysÅ‚owami jeżeli zawiera spacje.\n" #: main.c:523 msgid "WARNING: -a is deprecated, use -m instead.\n" msgstr "OSTRZEÅ»ENIE: -a jest przestarzaÅ‚e, użyj -m.\n" #: main.c:568 #, c-format msgid "Compiled with prefix: %s\n" msgstr "Skompilowane z prefiksem: %s\n" #: main.c:578 msgid "ERROR: Pal conf file required after -f argument." msgstr "BÅÄ„D: Plik conf wymagany po argumencie -f." #: main.c:595 msgid "ERROR: *.pal file required after -p argument." msgstr "BÅÄ„D: Plik *.pal wymagany po argumencie -p." #: main.c:610 msgid "ERROR: Username required after -u argument." msgstr "BÅÄ„D: Nazwa użytkownika wymagana po argumencie -u." #: main.c:627 msgid "ERROR: Regular expression required after -s argument." msgstr "BÅÄ„D: Wyrażenie regularne wymagane po argumencie -s." #: main.c:641 msgid "ERROR: Number required after -x argument." msgstr "BÅÄ„D: Wymagana liczba po argumencie -x." #: main.c:650 msgid "ERROR: Bad argument:" msgstr "BÅÄ„D: ZÅ‚y argument:" #: main.c:827 msgid "Manage events" msgstr "ZarzÄ…dzaj zdarzeniami" #: main.c:829 msgid "Press Control+c at any time to cancel.\n" msgstr "NaciÅ›nij Control+c w każdej chwili aby anulować.\n" #: main.c:834 msgid "Add an event." msgstr "Dodaj wydarzenie." #: main.c:836 msgid "Edit an event." msgstr "Edytuj wydarzenie." #: main.c:838 msgid "Delete an event." msgstr "UsuÅ„ wydarzenie." #: main.c:840 msgid "Remind me about an event (with at/cron)." msgstr "Przypomni mi o tym wydarzeniu (za pomocÄ… at/cron)" #: main.c:842 msgid "Exit." msgstr "Wyjdź." #: main.c:844 msgid "Select action [1--5]: " msgstr "Wybierz opcje [1--5]: " #: output.c:327 msgid "Mo Tu We Th Fr Sa Su" msgstr "Pn Wt Åšr Cz Pi So Ni" #: output.c:329 msgid "Su Mo Tu We Th Fr Sa" msgstr "Ni Pn Wt Åšr Cz Pi So" #: output.c:583 msgid "Today" msgstr "DziÅ›" #: output.c:585 msgid "Tomorrow" msgstr "Jutro" #: output.c:587 msgid "Yesterday" msgstr "Wczoraj" #: output.c:589 #, c-format msgid "%d days away" msgstr "za %d dni" #: output.c:591 #, c-format msgid "%d days ago" msgstr "%d dni temu" #: output.c:639 msgid "No events." msgstr "Brak wydarzeÅ„." #: input.c:188 #, c-format msgid "WARNING: File is missing 2 character marker and event type: %s\n" msgstr "OSTRZEÅ»ENIE: W pliku brakuje dwu znakowego oznaczenia typu wydarzenia: %s\n" #: input.c:207 msgid "ERROR: First line is improperly formatted.\n" msgstr "BÅÄ„D: Pierwszy wiersz jest nieprawidÅ‚owo sformatowany.\n" #: input.c:208 input.c:275 input.c:292 msgid "FILE" msgstr "PLIK" #: input.c:210 input.c:276 input.c:293 msgid "LINE" msgstr "WIERSZ" #: input.c:216 #, c-format msgid "ERROR: First line is not ASCII or UTF-8 in %s.\n" msgstr "BÅÄ„D: Pierwszy wiersz nie jest poprawnym ASCII lub UTF-8 w %s.\n" #: input.c:274 msgid "ERROR: Invalid date string.\n" msgstr "BÅÄ„D: Niepoprawny format daty.\n" #: input.c:291 msgid "ERROR: Event description missing.\n" msgstr "BÅÄ„D: Brak opisu zdarzenia.\n" #: input.c:306 #, c-format msgid "ERROR: Event text '%s' is not ASCII or UTF-8 in file %s.\n" msgstr "BÅÄ„D: Tekst zdarzenia '%s' nie jest poprawnym ASCII lub UTF-8 w pliku %s.\n" #: input.c:339 msgid "Expunged" msgstr "Wyczyszczone" #: input.c:394 del.c:54 #, c-format msgid "ERROR: Can't write file: %s\n" msgstr "BÅÄ„D: Nie można zapisać pliku: %s\n" #: input.c:395 #, c-format msgid "File will not be expunged: %s" msgstr "Plik nie zostanie wyczyszczony: %s" #: input.c:446 del.c:87 #, c-format msgid "ERROR: Can't rename %s to %s\n" msgstr "BÅÄ„D: Nie można zmienić nazwy z %s na %s\n" #: input.c:465 #, c-format msgid "ERROR: File doesn't exist: %s\n" msgstr "BÅÄ„D: Plik nie istnieje: %s\n" #: input.c:488 #, c-format msgid "ERROR: Can't find file. I tried %s and %s.\n" msgstr "BÅÄ„D: Nie można znaleźć pliku. PróbowaÅ‚em %s i %s.\n" #: input.c:511 #, c-format msgid "Reading: %s\n" msgstr "Czytam: %s\n" #: input.c:514 del.c:46 #, c-format msgid "ERROR: Can't read file: %s\n" msgstr "BÅÄ„D: Nie można odczytać pliku: %s\n" #: input.c:533 msgid "Looking for data to expunge.\n" msgstr "Szukam danych do wyczyszczenia.\n" #: input.c:542 #, c-format msgid "ERROR: Can't open file: %s\n" msgstr "BÅÄ„D: Nie można otworzyć pliku: %s\n" #: input.c:555 #, c-format msgid "NOTE: Creating %s\n" msgstr "INFO: Tworze %s\n" #: input.c:556 msgid "" "NOTE: Edit ~/.pal/pal.conf to change how and if certain events are " "displayed.\n" msgstr "INFO: Edytuj ~/.pal/pal.conf w celu zmiany jak i czy wydarzenia sÄ… wyÅ›wietlane.\n" #: input.c:564 #, c-format msgid "ERROR: Can't create directory: %s\n" msgstr "BÅÄ„D: Nie można utworzyć katalogu: %s\n" #: input.c:580 msgid "ERROR: Can't open file: /etc/pal.conf\n" msgstr "BÅÄ„D: Nie można otworzyć pliku: /etc/pal.conf\n" #: input.c:581 msgid "ERROR: Can't open file: " msgstr "BÅÄ„D: Nie można otworzyć pliku: " #: input.c:581 msgid "/share/pal/pal.conf\n" msgstr "/share/pal/pal.conf\n" #: input.c:582 msgid "ERROR: This indicates an improper installation.\n" msgstr "BÅÄ„D: To oznacza niewÅ‚aÅ›ciwÄ… instalacjÄ™.\n" #: input.c:589 #, c-format msgid "ERROR: Can't create/write file: %s\n" msgstr "BÅÄ„D: Nie można stworzyć/zapisać plik: %s\n" #: input.c:663 input.c:712 #, c-format msgid "ERROR: Invalid color '%s' in file %s." msgstr "BÅÄ„D: NiewÅ‚aÅ›ciwy kolor '%s' w pliku %s." #: input.c:665 input.c:714 msgid "Valid colors:" msgstr "WÅ‚aÅ›ciwe kolory:" #: input.c:737 #, c-format msgid "ERROR: Invalid line (File: %s, Line text: %s)\n" msgstr "BÅÄ„D: NiewÅ‚aÅ›ciwy wiersz (Plik: %s, Tekst: %s)\n" #: input.c:744 #, c-format msgid "" "Done reading data (%d events, %d files).\n" "\n" msgstr "Dane odczytano (%d wydarzeÅ„, %d pliki(ów)).\n" #: rl.c:69 msgid "WARNING: Failed to convert your input into UTF-8.\n" msgstr "OSTRZEÅ»ENIE: Nie udaÅ‚o siÄ™ skonwertowanie podanego teksty do UTF-8.\n" #: rl.c:75 msgid "Converted string to UTF-8." msgstr "Wpis skonwertowano do UTF-8." #: rl.c:93 rl.c:96 msgid "y" msgstr "y" #: rl.c:94 msgid "n" msgstr "n" #: rl.c:130 msgid "Use \"today\" to access TODO events." msgstr "Użyj \"dzisiaj\" aby uzyskać dostÄ™p do wydarzeÅ„ TODO." #: rl.c:133 rl.c:238 msgid "" "Valid date formats include: yyyymmdd, Jan 1 2000, 1 Jan 2000, 4 days away" msgstr "" "Poprawny format daty zawiera: rrrrmmdd, Jan 1 2000, 1 Jan 2000, " "za 4 dni, nastÄ™pny pn" #: rl.c:135 msgid "Date for event or search string: " msgstr "Data wydarzenia lub tekst do wyszukania: " #: rl.c:156 rl.c:190 msgid "Use \"0\" to use a different date or search string." msgstr "Użyj \"0\" w celu użycia innej daty albo innego tekstu szukania." #: rl.c:158 rl.c:192 msgid "Select event number: " msgstr "Wybierz numer wydarzenia: " #: rl.c:172 rl.c:206 msgid "" "This event is in a global calendar file. You can change this event only by " "editing the global calendar file manually (root access might be required)." msgstr "" "To wydarzenie jest w pliku globalnym kalendarza. Możesz zmienić to wydarzenie wyłącznie " "poprzez rÄ™cznÄ… edycjÄ™ pliku globalnego kalendarza (mogÄ… być wymagane " "uprawnienia użytkownika root)" #: rl.c:240 msgid "Date for event: " msgstr "Data wydarzenia: " #: rl.c:250 msgid "Events on the date you selected:\n" msgstr "Inne wydarzenia z datÄ… którÄ… wybraÅ‚eÅ›:\n" #: rl.c:257 msgid "Is this the correct date?" msgstr "Czy ta data jest poprawna?" #: rl.c:260 msgid "%a %e %b %Y - Accept? [y/n]: " msgstr "%a %e %b %Y - Akceptujesz? [y/n]: " #: html.c:151 html.c:161 latex.c:75 latex.c:85 msgid "Sunday" msgstr "Niedziela" #: html.c:153 latex.c:77 msgid "Monday" msgstr "PoniedziaÅ‚ek" #: html.c:154 latex.c:78 msgid "Tuesday" msgstr "Wtorek" #: html.c:155 latex.c:79 msgid "Wednesday" msgstr "Åšroda" #: html.c:156 latex.c:80 msgid "Thursday" msgstr "Czwartek" #: html.c:157 latex.c:81 msgid "Friday" msgstr "PiÄ…tek" #: html.c:158 latex.c:82 msgid "Saturday" msgstr "Sobota" #: add.c:36 msgid "1st" msgstr "1" #: add.c:37 msgid "2nd" msgstr "2" #: add.c:38 msgid "3rd" msgstr "3" #: add.c:39 msgid "4th" msgstr "4" #: add.c:40 msgid "5th" msgstr "5" #: add.c:41 msgid "6th" msgstr "6" #: add.c:42 msgid "7th" msgstr "7" #: add.c:43 msgid "8th" msgstr "8" #: add.c:44 msgid "9th" msgstr "9" #: add.c:45 msgid "10th" msgstr "10" #: add.c:56 msgid "Does this event have starting and ending dates? " msgstr "Czy te wydarzenie ma datÄ™ poczÄ…tkowÄ… i koÅ„cowÄ…?" #: add.c:58 add.c:129 msgid "[y/n]: " msgstr "[y/n]: " #: add.c:76 add.c:98 msgid "Start date: " msgstr "PoczÄ…tkowa data: " #: add.c:83 add.c:100 msgid "End date: " msgstr "KoÅ„cowa data: " #: add.c:90 msgid "ERROR: The end date is the same as or before the start date.\n" msgstr "BÅÄ„D: Data koÅ„cowa jest taka sama lub wczeÅ›niej niż data poczÄ…tkowa.\n" #: add.c:102 msgid "Accept? [y/n]:" msgstr "Zaakceptować? [y/n]" #: add.c:125 msgid "Is the event recurring? " msgstr "Czy te wydarzenie jest powtarzajÄ…ce siÄ™? " #: add.c:138 msgid "Select how often this event occurs\n" msgstr "Wybierz jak czÄ™sto to wydarzenie powtarza siÄ™\n" #: add.c:141 msgid "- Daily\n" msgstr "- Dziennie\n" #: add.c:145 #, c-format msgid "- Weekly: Every %s\n" msgstr "- Tygodniowo: Każdy %s\n" #: add.c:148 #, c-format msgid "- Monthly: Day %d of every month\n" msgstr "- MiesiÄ™cznie: Każdego %d miesiÄ…ca\n" #: add.c:154 #, c-format msgid "- Monthly: The %s %s of every month\n" msgstr "- MiesiÄ™cznie: %s %s każdego miesiÄ…ca\n" #: add.c:159 msgid "- Annually: %d %s\n" msgstr "- Rocznie: Ostatni %d w %s\n" #: add.c:166 #, c-format msgid "- Annually: The %s %s of every %s\n" msgstr "- Rocznie: %s %s każdego %s\n" #: add.c:176 #, c-format msgid "- Monthly: The last %s of every month\n" msgstr "- MiesiÄ™cznie: Ostatni %s każdego miesiÄ…ca\n" #: add.c:181 #, c-format msgid "- Annually: The last %s in %s\n" msgstr "- Rocznie: Ostatni %s w %s\n" #: add.c:189 msgid "Select type [1--8]: " msgstr "Wybierz typ [1--8]: " #: add.c:191 msgid "Select type [1--6]: " msgstr "Wybierz typ [1--6]: " #: add.c:323 msgid "What is the description of this event?\n" msgstr "Jaki jest opis tego wydarzenia?\n" #: add.c:332 edit.c:48 msgid "Description: " msgstr "Opis: " #: add.c:335 edit.c:51 msgid "Is this description correct? [y/n]: " msgstr "Czy ten opis jest poprawny? [y/n]: " #: add.c:348 msgid "Calendar file (usually ending with \".pal\") to add event to:\n" msgstr "Plik z kalendarzem (zazwyczaj koÅ„czÄ…cy siÄ™ z \".pal\") do którego dodać wydarzenie:\n" #: add.c:383 #, c-format msgid "ERROR: %s is a directory.\n" msgstr "BÅÄ„D: %s jest katalogiem.\n" #: add.c:390 #, c-format msgid "WARNING: %s does not exist.\n" msgstr "OSTRZEÅ»ENIE: %s nie istnieje.\n" #: add.c:392 msgid "Create? [y/n]: " msgstr "Stworzyć? [y/n]: " #: add.c:400 #, c-format msgid "ERROR: Can't create %s.\n" msgstr "BÅÄ„D: Nie można utworzyć %s.\n" #: add.c:411 #, c-format msgid "Information for %s:\n" msgstr "Informacje do %s:\n" #: add.c:413 msgid "2 character marker for calendar: " msgstr "2 znakowe oznaczenie kalendarza: " #: add.c:416 msgid "Calendar title: " msgstr "TytuÅ‚ kalendarza: " #: add.c:422 msgid "" "If you want events in this new calendar file to appear when you run pal,\n" " you need to manually update ~/.pal/pal.conf" msgstr "" "Jeżeli chcesz aby wydarzenia z nowego kalendarza wyÅ›wietlaÅ‚y sie gdy uruchamiasz pal,\n" " musisz rÄ™cznie uaktualnić ~/.pal/pal.conf" #: add.c:456 #, c-format msgid "ERROR: Can't read from file %s.\n" msgstr "BÅÄ„D: Nie można czytać z pliku %s.\n" #: add.c:457 add.c:474 msgid "Try again? [y/n]: " msgstr "Spróbować ponownie? [y/n]: " #: add.c:473 #, c-format msgid "ERROR: Can't write to file %s.\n" msgstr "BÅÄ„D: Nie można zapisać do pliku %s.\n" #: add.c:487 #, c-format msgid "Wrote new event \"%s %s\" to %s.\n" msgstr "Zapisano nowe wydarzenie \"%s %s\" do %s.\n" #: add.c:500 msgid "" "Use \"TODO\" to make an event that always occurs on the current date. If " "the event is recurring, select one of the days the event occurs on." msgstr "Użyj \"TODO\" żeby wydarzenie zawsze pokazywaÅ‚o siÄ™ z aktualnÄ… datÄ…. Jeżeli wydarzenie jest powtarzajÄ…ce siÄ™, wybierz dzieÅ„ w który wydarzenie ma powtarzać siÄ™." #: add.c:519 msgid "Add an event" msgstr "Dodaj wydarzenie" #: edit.c:39 msgid "What is the new description of this event?\n" msgstr "Jaki jest nowy opis tego wydarzenia?\n" #: edit.c:59 msgid "Editing the event:\n" msgstr "Edycja wydarzenia:\n" #: edit.c:67 msgid "Edit the event date (how often it happens, start date, end date)." msgstr "Edytuj datÄ™ wydarzenia (jak czÄ™sto zdarza siÄ™, data poczÄ…tkowa, data koÅ„cowa)." #: edit.c:69 msgid "Edit the event description." msgstr "Edytuj opis wydarzenia." #: edit.c:71 msgid "Select action [1--2]: " msgstr "Wybierz akcje [1--2]: " #: edit.c:103 msgid "Edit an event" msgstr "Edytuj wydarzenie" #: del.c:47 del.c:55 del.c:88 msgid " The event was NOT deleted." msgstr " Wydarzenie NIE zostaÅ‚a usuniÄ™te." #: del.c:96 #, c-format msgid "Event removed from %s.\n" msgstr "Wydarzenie usuniÄ™to z %s.\n" #: del.c:99 #, c-format msgid "ERROR: Couldn't find event to be deleted in %s" msgstr "BÅÄ„D: Nie można byÅ‚o znaleź wydarzenia do usuniÄ™cia %s" #: del.c:110 msgid "Delete an event" msgstr "UsuÅ„ wydarzenie" #: del.c:114 msgid "" "If you want to delete old events that won't occur again, you can use pal's -" "x option instead of deleting the events manually." msgstr "Jeżeli chcesz usunÄ…c stare nie aktualne wydarzenia, możesz użyć opcji -x zamiast rÄ™cznie usuwać wydarzenia." #: del.c:120 msgid "You have selected to delete the following event:\n" msgstr "WybraÅ‚eÅ› do usuniÄ™cia nastÄ™pujÄ…ce wydarzenie:\n" #: del.c:123 msgid "Are you sure you want to delete this event? [y/n]: " msgstr "Czy jesteÅ› pewien że chcesz usunÄ…c to wydarzenie? [y/n]: " #: remind.c:45 msgid "Event reminder" msgstr "Przypominacz wydarzenia " #: remind.c:49 msgid "" "This feature allows you to select one event and have an email sent to you " "about the event at a date/time that you provide. If the event is recurring, " "you will only receive one reminder. You MUST have atd, crond and sendmail " "installed and working for this feature to work." msgstr "" "Ta opcja pozwala wybrać jedno z wydarzeÅ„ o którym chcemy być powiadomieni email'em " "o czasie który podasz. Jeżeli te wydarzenie jest powtarzajÄ…ce siÄ™ zostaniesz " "powiadomiony tylko jeden raz. MUSISZ mieć atd, crond oraz sendmail " "zainstalowany i uruchomiony." #: remind.c:78 msgid "Remind me on (HH:MM YYYY-MM-DD): " msgstr "Przypomni mi o (HH:MM RRRR-MM-DD): " #: remind.c:83 msgid "Username on local machine or email address: " msgstr "Nazwa użytkownika na lokalnej maszynie lub adres email: " #: remind.c:101 msgid "Event: " msgstr "Wydarzenie: " #: remind.c:105 msgid "Event date: " msgstr "Data wydarzenia:: " #: remind.c:114 msgid "Event type: " msgstr "Typ wydarzenia: " #: remind.c:123 msgid "Attempting to run 'at'...\n" msgstr "Próba uruchomienia 'at'...\n" #: remind.c:128 msgid "" "ERROR: Date string was invalid or could not run 'at'. Is 'atd' running?" msgstr "" "BÅÄ„D: Tekst daty byÅ‚ zÅ‚y lub nie można byÅ‚o uruchomić 'at'. Czy 'atd' jest uruchomiony?" #: remind.c:132 msgid "Successfully added event to the 'at' queue.\n" msgstr "Pomyslnie dodano wydarzenie do kolejki 'at'.\n" #: search.c:106 #, c-format msgid "" "[ Begin search results: %s ]\n" "[ From %s to %s inclusive ]\n" "\n" msgstr "" "[ PoczÄ…tek wyników wyszukiwania: %s ]\n" "[ Od %s do %s włącznie ]\n" "\n" #: search.c:163 #, c-format msgid "[ End search results: %s ] [ %d %s found ]\n" msgstr "[ Koniec wyników wyszukiwania: %s ] [ %d %s znaleziono ]\n" #~ msgid "- Annually: On day %d of every %s\n" #~ msgstr "- Rocznie: Dnia %d każdego %s\n" #~ msgid "Is this the date you want to add an event to?\n" #~ msgstr "Czy to jest ta data z którÄ… chcesz dodać wydarzenie?\n" #~ msgid "" #~ "NOTE: Use \"today\" to edit a TODO item. If the event is recurring, " #~ "select one of the days the event occurs on." #~ msgstr "INFO: Użyj \"dzisiaj\" w celu edycji pozycji TODO. Jeżeli wydarzenie jest powtarzajÄ…ce siÄ™ wbierz jeden z dni w których wydarzenie wystÄ™puje." #~ msgid "What is the number of the event you want to edit?\n" #~ msgstr "Jaki jest numer wydarzenia które chcesz edytować?\n" #~ msgid "" #~ "You selected an event in a global calendar file. pal will only allow you " #~ "to edit local calendar files.\n" #~ msgstr "WybraÅ‚eÅ› wydarzenie które jest w pliku kalendarza globalnego. Pal pozwala tylko na edycje lokalnych plików kalendarza.\n" pal-0.4.3/INSTALL0000644000175000017500000000652511043370327013227 0ustar kleptogkleptogCONTENTS: 1: Compilation and installation of pal 1.1: Directly from source 1.2: RPM-based distributions 2: Compilation and installation of ical2pal & pal2ical ----------------------------------------------------------- +---------------------------------------------------------+ | 1: Compilation and installation of pal | +---------------------------------------------------------+ ----- 1.1: Directly from source ----- 1) Untar/unzip the pal-x.x.x.tgz package: tar -xzf pal-x.x.x.tgz cd pal-x.x.x/src 2) (Optional) By default, pal is installed into directories under /usr. Some distributions usually install things to /usr/local. To change where pal will be installed to, change the "prefix" line at the top of Makefile.defs. 3) Compile pal make 4) Install pal: WITH root access: Run "make install" as root. This will install several files including the pal binary, global calendar files, and the man page. (Special note to developers: Use "make install-no-rm" if you don't want the install process to attempt to remove old pal files. This is useful for when creating a package file for package managers such as portage or rpm.) WITHOUT root access; single user: Run "mkdir ~/.pal" as the user you want to run pal as. Copy the pal-x.x.x/pal.conf file and whatever calendars you want from pal-x.x.x/share into ~/.pal. To view the man page, run "man pal-x.x.x/pal.1.template". 5) (Optional) Delete pal-x.x.x.tgz and the pal-x.x.x directory. 6) Run pal by typing "pal" at the commandline. This will create ~/.pal and ~/.pal/pal.conf if they do not already exist. 7) Customize - Explore settings in ~/.pal/pal.conf - You can create your own calendar file in ~/.pal and tell pal to load them by making changes to ~/.pal/pal.conf. For more information see pal's man page. TO UNINSTALL, run "make uninstall" in src while root. ----- 1.2: RPM-Based distributions ----- (.tgz -> .src.rpm -> .rpm) 1) Generate the .src.rpm file. As root, run: rpmbuild -ts pal-x.x.x.tgz 2) Compile the .src.rpm file to a .rpm file. As root, run (where SRCRPMFILE is the filename that was displayed in while running the command in step 1): rpmbuild --rebuild SRCRPMFILE 3) Install as root. Where RPMFILE is the filename displayed at the end of the output of the step 2. If installing for the first time: rpm -ivh RPMFILE If upgrading a previous installation: rpm -Uvh RPMFILE 4) (Optional) Remove unneeded files: pal-x.x.x.tgz, RPMFILE and SRCRPMFILE 5) Follow steps 6 and 7 in the section above (Installing DIRECTLY FROM SOURCE). TO UNINSTALL, run the following command as root: rpm -e pal +---------------------------------------------------------+ | 2: Compilation and installation of ical2pal & pal2ical | +---------------------------------------------------------+ ical2pal and pal2ical are conversion utilities that convert calendars between pal's calendar format and the ical format (RFC 2445). You must have libical (http://www.softwarestudio.org/libical/) installed to compile and use the conversion utilities. You do not need to install the utilities to use pal. NOTE: ical2pal and pal2ical are very new and likely contain bugs. 1) Untar/unzip the pal-x.x.x.tgz package: tar -xzf pal-x.x.x.tgz cd pal-x.x.x/src/convert 2) make ical 3) make ical-install pal-0.4.3/COPYING0000644000175000017500000004313111043370327013223 0ustar kleptogkleptog GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Library General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. GNU GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. 1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. 4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. 6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. 10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA Also add information on how to contact you by electronic and paper mail. If the program is interactive, make it output a short notice like this when it starts in an interactive mode: Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. , 1 April 1989 Ty Coon, President of Vice This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Library General Public License instead of this License. pal-0.4.3/pal.spec.template0000644000175000017500000000161311043370327015431 0ustar kleptogkleptogSummary: A command line calendar that displays holidays and user-defined events. Name: pal Version: Release: 1 Copyright: GPL Group: Applications/Productivity Url: http://palcal.sourceforge.net/ Source: %{name}-%{version}.tgz BuildRoot: /var/tmp/%{name}-buildroot %description pal is a command line calendar that displays holidays and user-defined events that are specified in text files. %define debug_package %{nil} %prep %setup -q %build cd src make OPT="$RPM_OPT_FLAGS" %install rm -rf $RPM_BUILD_ROOT cd src make DESTDIR="$RPM_BUILD_ROOT" install-no-rm %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) /usr/bin/pal /usr/share/man/man1/pal.1.gz /usr/share/doc/pal-%{version}/* /usr/share/locale/*/*/* /usr/share/pal /etc/pal.conf %changelog * Fri Mar 19 2004 Scott Kuhl - Updated list of installed files * Mon Aug 4 2003 Scott Kuhl - Created spec file pal-0.4.3/pal.1.template0000644000175000017500000003243311043370327014643 0ustar kleptogkleptog.\" Copyright (c) 2004--2006, Scott Kuhl .\" .\" This is free documentation; you can redistribute it and/or .\" modify it under the terms of the GNU General Public License as .\" published by the Free Software Foundation; either version 2 of .\" the License, or (at your option) any later version. .\" .\" The GNU General Public License's references to "object code" .\" and "executables" are to be interpreted as the output of any .\" document formatting or typesetting system, including .\" intermediate and printed output. .\" .\" This manual is distributed in the hope that it will be useful, .\" but WITHOUT ANY WARRANTY; without even the implied warranty of .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the .\" GNU General Public License for more details. .\" .\" You should have received a copy of the GNU General Public .\" License along with this manual; if not, write to the Free .\" Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, .\" USA. .TH pal 1 .SH NAME pal \- calendar with events .SH SYNOPSIS .TP 3 \fBpal \fI[options]\fR .SH DESCRIPTION .PP \fBpal\fR is a command\(hyline calendar utility. It displays a \fBcal(1)\fR\(hylike calender and events specified in text files. .SH OPTIONS The following options are provided by \fBpal\fR: .TP .B \-d \fIdate\fB Show events on the given date. Valid formats for \fIdate\fR include: dd, mmdd, yyyymmdd, 'yesterday', 'today', 'tomorrow', 'n days away', 'n days ago', first two letters of weekday, 'next ' followed by first two letters of weekday, 'last ' followed by first two letters of weekday, '1 Jan 2000', 'Jan 1 2000'. .TP .B \-r \fIn\fB Display events occurring in the next \fIn\fR days (counting today). By default, \fIn\fR is 0 and no events are displayed. For example, using \fI\-r 1\fR makes \fBpal\fR display events occurring today. If \fB\-d\fR is used too, the range is relative to \fIdate\fR instead of the current date. .TP .B \-r \fIp\fB\-\fIn\fB Display a list of events occurring in the past \fIp\fR days (not counting today) and the next \fIn\fR days (counting today). For example \fI\-r 1\-1\fR will show yesterday's and today's events. If \fB\-d\fR is used too, the range is relative to \fIdate\fR instead of the current date. .TP .B \-s \fIregex\fB Search for any occurrences of an event matching the regular expression (\fIregex\fR) occurring in the range of dates specified with \fB\-r\fR. This command searches both the event description and the type of event (specified at the top of a calendar file). This search is case insensitive. .TP .B \-x \fIn\fB Expunge events that are \fIn\fR or more days old if they do not occur again in the future. \fBpal\fR will not expunge events from the calendars loaded from \fI/usr/share/pal\fR; even if you are root and you have added events to the calendars that are not recurring. When \fB\-x\fR is used with \fB\-v\fR, the events that are expunged will be displayed. .TP .B \-c \fIn\fB Display a calendar with \fIn\fR lines (default: 5). .TP .B \-f \fIfile\fB Load \fIfile\fR instead of \fI~/.pal/pal.conf\fR. .TP .B \-u \fIusername\fB Load /home/\fIusername\fR/.pal/pal.conf instead of \fI~/.pal/pal.conf\fR. .TP .B \-p \fIpalfile\fB Override the .pal files loaded from pal.conf. This will only load \fIpalfile\fR. For convenience, if \fIpalfile\fR is a relative path, pal looks for the file relative from \fI~/.pal/\fR, if not found, it tries relative to \fI/usr/share/pal/\fR, if not found it tries relative to your current directory. (This behavior might change in the future.) Using an absolute path will work as you expect it to. .TP .B \-m Manage events interactively. Events can be added, modified and deleted with this interface. .TP .B \-\-color Force use of colors, regardless of terminal type. .TP .B \-\-nocolor Do not use colors, regardless of terminal type. .TP .B \-\-mail Generates output readable by sendmail by adding "From:" and "Subject:" fields and forcing \fB\-\-nocolor\fR. For example, you could mail yourself a reminder of the upcoming events in the next week with \fBpal \-\-mail \-r 7 | sendmail username\fR. Note: For the calendar to appear correctly, make sure your email client is using a fixed width font. .TP .B \-\-html Generates a HTML calendar suitable for display on a web page. It does not generate a complete HTML document so that you can add your website's header and footer around the calendar. The number of months shown on the calendar can be adjusted with \fB\-c\fR. You will need to use Cascading Style Sheets (CSS) to change how the calendar appears; if you do not use a style sheet, the calendar will not have any borders. See \fI/usr/share/doc/pal/example.css\fR for an example style. SECURITY NOTE: If you set up pal so it is being executed server\(hyside, it is recommended that you do not allow web page visitors to directly change the parameters sent to pal. Allowing users to pass strange parameters (such as extremely long ones) can be a security risk. .TP .B \-\-latex Generates a LaTeX source for a calendar that can be used to generate a printer\(hyfriendly DVI (run "pal \-\-latex > file.tex; latex file.tex"), PostScript or PDF (run "pal \-\-latex > file.tex; pdflatex file.tex"). The number of months shown on the calendar can be adjusted with \fB\-c\fR. .TP .B \-v Verbose output. .TP .B \-\-version Display version information. .TP .B \-h, \-\-help Display a help message. .SH EVENT DESCRIPTIONS .TP 3 .B Years since year YYYY pal will replace !YYYY! (where YYYY is a year) with the current year minus YYYY. This feature is particularly useful for birthdays. For example, the event text for a birthday could be: John Doe was born on this day in 1990. He is !1990! years old. .TP 3 .B Sort by time If events have a time in the event description, pal will sort these events by time. The time in the event description must be of the format \fIh:mm\fR or \fIhh:mm\fR (where \fIhh\fR is 0\-23). If an event has more than one time in the event description, pal will sort the event by the first time. Events that do not have times in them are shown before all the events that do have times. Events without times are sorted in the order that they are loaded in pal.conf. .SH FILE FORMATS Unless \fB\-f\fR or \fB\-u\fR is used, \fBpal\fR looks for (or tries to create if it doesn't exist) a configuration file named \fI~/.pal/pal.conf\fR. \fBpal.conf\fR contains settings for \fBpal\fR and a list other files that contain events to be displayed on the calendar. The file formats for \fBpal.conf\fR and the \fBevent files\fR are described below. .TP 3 .B pal.conf .RS 3 .TP .B file \fIfilename\fR [ \fI(color)\fR ] Loads an \fBevent file\fR named \fIfilename\fR. If \fIfilename\fR isn't found in \fI~/.pal\fR, \fBpal\fR will look for it in \fI/usr/share/pal\fR. The color parameter is optional, it will display the events in the file with the given color. Valid colors: black, red, green, yellow, blue, magenta, cyan, white .TP .B file_hide \fIfilename\fR [ \fI(color)\fR ] Loads an \fBevent file\fR name \fIfilename\fR. These events are not indicated in the calendar that is printed, but they are displayed when the \fI\-r\fR argument is used. If \fIfilename\fR isn't found in \fI~/.pal\fR, \fBpal\fR will look for it in \fI/usr/share/pal\fR. The color parameter is optional, it will display the events in the file with the given color. Valid colors: black, red, green, yellow, blue, magenta, cyan, white .TP .B event_color \fIcolor\fR The default color used for events. Valid colors: black, red, green, yellow, blue, magenta, cyan, white .TP .B week_start_monday If this keyword is defined, the calendar weeks start on Monday instead of Sunday. .TP .B date_fmt \fIstring\fR Changes how dates are displayed when the \fB\-r\fR \fB\-d\fR or \fB\-s\fR arguments are used. \fIstring\fR can be a date format string that follows the format used by \fBstrftime(3)\fR. Type \fBman strftime\fR for more information. \fIstring\fR is set to \fB%a %e %b %Y\fR by default (example: Sun 8 Aug 2010). .TP .B reverse_order Display all event listings in descending order. .TP .B hide_event_type Hide the event type (shown in before a ':') when listing events. The event type is defined at the top of the file that the event is found in. .TP .B cal_on_bottom Display calendar at the end of the output. .TP .B no_columns Display calendar in one column instead of two. .TP .B compact_list List events that are shown when using \-r in a more compact form. .TP .B compact_date_fmt Format for the date displayed when compact_list is used. See date_fmt for more information. .TP .B default_range \fIrange\fR If you get tired of always using \-r, you can set the default value for \-r here. See the information on \-r above to see possible values for \fIrange\fR. Note: Remember that this will affect what is displayed when \-d and \-s are used too. .RE .B Event Files .RS 3 Event files are ASCII or UTF\-8 text files (usually with a .pal ending) that define events for \fBpal\fR to show. Example event files can be found in \fI/usr/share/pal\fR. The first line in these files indicate settings that apply to all of the events in the file. The first line starts with two characters that should be used in the calendar that \fBpal\fR displays. A longer description of the kinds of events in the file follows the two characters. This description will be displayed when the \fB\-r\fR argument is used. All other lines in the file are in the format \fIdate\fR \fIevent\fR. \fIdate\fR defines when the event occurs and \fIevent\fR is a string that describes the event. Below is a description of the different strings that can be used with \fIdate\fR: .TP .B Events that occur only once Use the format \fIyyyymmdd\fR. .TP .B Daily events The format \fIDAILY\fR can be used for an event that happens every day. .TP .B Weekly events The format \fIMON\fR, \fITUE\fR, \fIWED\fR, \fITHU\fR, \fIFRI\fR, \fISAT\fR and \fISUN\fR can be used for an event that happens every week. .TP .B Monthly events Use the format \fI000000dd\fR. .TP .B Annual events Use the format \fI0000mmdd\fR. .TP .B Annual: Events that occur on the Nth day of a month. Use the format \fI*mmnd\fR. Where \fId\fR is the day (1 = Sunday, 7 = Saturday). Example: *1023 (10=Oct; 2="second"; 3=Tuesday ==> Second Tuesday in October, every year). .TP .B Monthly: Events that occur on the Nth day of a month. Use the format \fI*00nd\fR. Where \fId\fR is the day (1 = Sunday, 7 = Saturday). Example: *0023 (2="second"; 3=Tuesday ==> Second Tuesday of every month). .TP .B Annual: Events that occur on a certain last day of a month Use the format \fI*mmLd\fR. Example: *10L3 (10=Oct; L=Last; 3=Tuesday ==> Last Tuesday in October). This is useful for some holidays. .TP .B Monthly: Events that occur on a certain last day of a month Use the format \fI*00Ld\fR. Example: *00L3 (3=Tuesday ==> Last Tuesday of every month). .TP .B "Todo" events The format \fITODO\fR can be used for an event that always happens on the day that you run pal. This enables you to use pal to keep track of items in your todo list(s). .TP .B Easter related events Use the format \fIEaster\fR for Easter Sunday. Use the format \fIEaster+nnn\fR for events that occur \fInnn\fR days after Easter. Use the format \fIEaster\(hynnn\fR for events that occur \fInnn\fR days before easter. .TP .B Recurring events with start and end dates If a recurring event has a starting date and an ending date, you can use the date format \fIDATE:START:END\fR where \fIDATE\fR is a recurring date format above. \fISTART\fR and \fIEND\fR are dates in the yyyymmdd format that specify the starting and ending date of the recurring event. \fISTART\fR and \fIEND\fR dates are inclusive. For example, if an event happens every Wednesday in October 2010, you could use this format: \fIWED:20101001:20101031\fR .TP .B Bi-weekly, Bi-annual, etc. events If a recurring event does only occurs every Nth occurence, you can add a \fI/N\fR to the event of the date string for that event. A start date must be specified. For example, a bi-monthly event that occurs on the first of the month can be specified as \fI00000001/2:20000101\fR. .RE .SH INTERNATIONALIZATION AND LOCALIZATION The calendar files that pal uses must be ASCII encoded or UTF\-8 encoded text files (ASCII is a subset of UTF\-8). UTF\-8 enables the calendar files to work on any system regardless of the default encoding scheme. When pal prints text, it converts the UTF\-8 characters into the local encoding for your system. If pal does not display international characters and you are using a UTF\-8 calendar file, check to make sure that your locale is set correctly. You can see your locale settings by running "locale". You can see the character set that pal is using for output by running pal with "\-v". If pal does not have a translation for your language and you are interested in creating a translation, see the po/README file that is distributed with the source code for pal. .SH FILES \fI~/.pal/pal.conf\fR: Contains configuration information for \fBpal\fR and a list of .pal text files that contain events. \fI/etc/pal.conf\fR: This pal.conf file is copied to ~/.pal/pal.conf when a user runs pal for the first time. \fI/usr/share/pal\fR: Contains several calendar files for \fBpal\fR. .SH BUGS Bugs may be reported via \fIhttp://palcal.sourceforge.net/\fR. .SH SEE ALSO strftime(3), cal(1), regex(7) .SH SIMILAR PROGRAMS \fBpal\fR is similar to BSD's \fBcalendar\fR program and GNU's more complex \fBgcal\fR program. .SH AUTHORS Scott Kuhl pal-0.4.3/ChangeLog0000644000175000017500000003167711043370327013756 0ustar kleptogkleptogversion 0.4.3 (28 July 2008) * Support colour in screen (Adam Lincoln) * Wait for keystroke after add event (Adam Lincoln) * Display flags used while compiling (Martijn van Oosterhout) * Fix warnings generated during DEBUG compilation (Martijn van Oosterhout) * Fix groff warning in manpage (Carsten Hey) * Use CPPFLAGS in makefiles (Martijn van Oosterhout) * Fix segfault when printing strings not valid in user's locale (Debian bug #492464) (Martijn van Oosterhout) version 0.4.2 (17 June 2008) * Added vcard2pal from http://youam.net/devel/vcard2pal/ with permission from author. * Fix extraneous output when using --mail option version 0.4.1 (2 June 2008) * Rewrote -m feature to use ncurses. (Scott Kuhl, Martijn van Oosterhout) * Rewrote code that handles how different types of events are described (PalEventType was added). (Martijn van Oosterhout) * Fixed bug that caused the ** markers around the date in the calendar to not be used when the day had multiple events with different markers/colors. (Scott Kuhl) * Added a new / to the date syntax, so you can say "every x days/weeks/months/years". (Martijn van Oosterhout) * Add show_weeknum option to pal.conf (Martijn van Oosterhout) * Added: ical2pal (requires libical) to convert calendars from ical format to pal's format. (Scott Kuhl) * Added: pal2ical to convert calendars from pal's format to the ical format. (Scott Kuhl) * Output from pal2ical now compatible with ipods. (Adam Byrtek) * --latex output now starts on date specified by -d (Martijn van Oosterhout) * Support for UTF8 characters for --html and --latex output improved. (Martijn van Oosterhout) * Added tags previously missing from --html output (Martijn van Oosterhout) * Minor --html bugs fixed. (Scott Kuhl, Stephen Smith) * --html: Different types of events can now have different colors (defined with CSS). (Scott Kuhl) * --html: Allow date specified with -d to be used to define what month should be first in the HTML calendar. If -d is not specified, the calendar will start by printing the current month. (Guy Brand) * Show events that do not have times in the event description before events that do have times in the event descriptions. (This reverses the old behavior). (Scott Kuhl) * Rewrote/simplified word wrapping code in pal_output_wrap() (Scott Kuhl) * Fix hyphens in man page (Javier Linares) * Added Turkish translation (Can Burak Cilingir) * Updated Swedish translation (Lars Bjarby) * Updated German translation (Bastian Kleineidam) version 0.3.4 (2 May 2004) * Fixed: file_hide feature * Created new interactive interface for adding/editing/deleting events that is started with the -m parameter. (-a is now deprecated in favor of -m). * Events can be sorted by times in event description. The time must be in 24-hour time format (h:mm or hh:mm). If more than one time is in the event description, the first time is used for sorting. Events with times in them are sorted and shown before all other events in the -r output. Events that do not have times in them are still sorted by the order they were loaded by ~/.pal/pal.conf. * When event text contains !YYYY! (example !1900!), that text will be replaced with the number of years since the year YYYY. * Added basic reminders of individual events through the use of at/cron. * Improved --html output. Individual days of the week can be styled differently. The -c argument now adjusts the number of months --html outputs (not the number of weeks). * Search feature defaults to searching events within the next 365 days (if you don't use -r with -s). * Move /usr/share/pal/pal.conf to /etc/pal.conf * Streamlined code for reading in calendar files * readline related pal functions are now in rl.c * Made pal more Debian friendly (Javier Linares) * Added Polish translation (Artur Gajda) * Added Swedish translation (Lars Bjarby) * Added Spanish translation (Javier Linares) * Updated German translation (Christopher Knoerle) version 0.3.3 (14 Mar 2004) * pal is now compatible with glib 2.0 (previously, 2.2 was required). * Make Easter related events work again * --help information is now wrapped according to terminal width. * Improved localization of -d 'n days ago' and -d 'n days away'. * Fixed a couple character encoding issues when adding events with -a. * pal now compiles on Cygwin and properly uses colors in a Cygwin terminal. * Fixed infinite loop when loading an empty .pal file. * When adding events with -a, do not allow users to use a '#' as the first character in the two character 'marker'. (Philipp Friedrich) * Properly escape text in event descriptions in LaTeX and HTML markup. * Several other small bug fixes. * Updated German translation (Christopher Knoerle) version 0.3.2 (6 Jan 2004) * Added new recurring event type: The Nth Monday/Tuesday/... of every month. * Added new recurring event type: The last Monday/Tuesday/... of every month. * man page updates for the two new recurring event types. * Added a LaTeX output feature * Minor bug fixes for when interactively adding events with "-a". * Fixed typos (including some pointed out by Christopher Knoerle) * Colors are now shown when using SSH inside of an aterm. (Christopher Knoerle) * Localized more strings, modified strings for easier localization. * Added German translation (Christopher Knoerle) version 0.3.1 (21 Dec 2003) * Improved international support: pal calendar files can now be either ASCII or UTF-8. man page for pal has a new internationalization section. Rewrote text wrapping code to work properly with multibyte UTF-8 characters. When using -a, pal attempts to convert user input to UTF-8 before writing to calendar file. * Wrote translation instructions in po/README * Added a note when creating a new calendar file with "pal -a" that you need to update ~/.pal/pal.conf in order to see the events in that calendar. * Minor Makefile improvements * CSS can now be easily used to style the output of --html version 0.3.0 (8 Nov 2003) * Added ability to assign colors to different .pal files in pal.conf * It is now possible to limit a recurring event to be between two dates. For example a yearly event on Jan 5th on years 2003 and 2004 can be written as: 00000105:20030101:20050101. The first date is a yearly event on Jan 5th. The second date is the "starting" date and the 3rd date is the ending date. * Interactively add events to .pal files with -a. It can add all types of events: one-time, recurring and recurring with start/end dates. * Added TODO keyword to be used before events in a calendar file. TODO can be used for events that always happen on the day that pal is being run on. This works well for reminding yourself daily of something in a todo list. * Added DAILY keyword to be used before events in a calendar file. Unlike TODO, DAILY events happen every day (not only on the current day). * Added MON, TUE, WED, THU, FRI, SAT and SUN keywords to be used before events in a calendar file. These events occur weekly. * Removed the yyyy00dd keyword in calendar files that was previously used to allow a monthly event to occur in only one year. This type of event can now be defined with the new recurring event start/end dates. * The date keywords (such as "Easter" and "TODO") in calendar files are now case insensitive. * Fixed a bug in the display of *mmnd events that occured sometimes. * Basic HTML output filter implemented (--html) * Slightly changed the format of event listings. Removed []'s and made dates bold. * Added default_range option in pal.conf * Minor calendar file updates * More date formats recognized by -d argument and better error checking * Added -p command-line argument * Added compact_list and compact_date_fmt options in pal.conf * Added event_color option in pal.conf * Fixed a bug that prevented use of absolute paths to .pal files in pal.conf * Added a pal-todo.pal file to the root of the tgz * Streamlined colorized output code * Attempt to fix an infinite loop on pal's first run on PPC * Several small improvements to Makefile * Added "prefix" variable in Makefile so pal can easily be installed to /usr/local instead of /usr * Fixed erroneous errors when running make with .d files missing * Fix compilation problems on FreeBSD version 0.2.5 (27 Sep 2003) * Fixed a segmentation fault that could occur when using the -u argument. * Added intelligent line wrapping and indention for events with a long text description. Words are no longer split between lines. * Single column calendar is used if terminal is too narrow. version 0.2.4 (29 Aug 2003) * Added search feature (-s) * Improved calendar reading code (fixed bugs, added more error checking) * Updated calendar files * Events are now displayed in the order that the files are loaded in the pal.conf file when there is > 1 event on a day. * Code improvements (more comments, code divided into smaller files) * -r can be used to display events that already happened. * The range set with -r is now relative to the current date or a date used with -d. * The word "range" describes what "-r" does better than "reminders." version 0.2.3 (11 Aug 2003) * IMPORTANT: Fixed expunging problems with global files. If you ran pal 0.2.2 with the -x argument, it is likely that some global pal files got copied from /use/share/pal to ~/.pal. It is recommended that you delete these copies if you want to see future updates to the global calendars provided with pal. * -x now expects number of days (not weeks) for consistency with other arguments. * Fixed mistakes in man page * Made Makefile compatible with older versions of sed that don't support -i (such the version in redhat 7.3) * Fixed many memory leaks * Error messages are now displayed for improperly formatted calendar files. * Added hide_remind_titles to pal.conf * Updates to several calendar files * Comments are now allowed in calendar files. * Added -u argument (similar to -f) * --mail works with -v * Simplified calendar reading code * Removed the bad German translation. An improved version is included in the tgz but is not installed. Translators are welcome to contribute to pal. version 0.2.2 (7 Aug 2003) * Added man page * Added calender to be displayed in columns (changes usage of -c slightly) * Added no_columns keyword to pal.conf * Added very rough German translation (set LANG to de_DE to use) * Added calendar files from the OpenBSD calendar program * Added capability to look for global event files in /usr/share/pal if they weren't found in ~/.pal * Added file_hide keyword to pal.conf * Added remind_reverse keyword to pal.conf * Added cal_on_bottom keyword to pal.conf * Changed usage of -r. It now uses days, not weeks * Allowed absolute paths to be specified after file_hide and file keywords in pal.conf * Error messages now use stderr---not stdout * Removed pretty_date() in main.c and its memory leak * Fixed output of -d argument when there is no event on the specified day * Added --mail argument * Added creation of ~/.pal/pal.conf if it doesn't exist and -f argument isn't used * Easter related events now can be defined in calendar files (instead of turning them on/off at compile time) * Removed README file. Information in README is now in INSTALL or the man page. * Show week before current week if calendar is more than 3 lines long * Made "today" on calendar bright white version 0.2.1 (5 Aug 2003) * Updates in Makefile * Added spec file for creation of rpms (not fully tested) * Dates displayed with -r argument are now translated correctly * Fixed deprecated glib function calls version 0.2.0 (31 Jul 2003) * IMPORTANT: The format of pal.conf has changed slightly to allow new customizations. Now, the "file" keyword must precede any calendar files that you want to load. * Added support for week_start_monday in pal.conf to display Monday as first day of the week * Added support for date_fmt in pal.conf to specify the format of the date displayed when using the -r argument * Support for comments (beginning with '#') in pal.conf file * Command line arguments are now case sensitive * Better terminal type detection for color * Removed unneeded colorization of blank spaces * Added very basic internationalization support (gettext) * Added install, uninstall and debug rules to Makefile * Modified dist rule in Makefile to put all files into a pal directory. Unpacking the file now creates a pal directory. * Fixed segmentation fault in optimized builds * Dates displayed with -r argument are now just bold----not bold and white version 0.1.1 (30 Jul 2003) * Created ChangeLog * Added color output feature (with crude checking of terminal type) * Added ability to load a different pal.conf file * Created separate file for output functions * Several other small updates * Added dist rule to Makefile version 0.1.0 (16 Jul 2003) * Initial public release pal-0.4.3/pal-0.4.3.spec0000644000175000017500000000162111043370327014256 0ustar kleptogkleptogSummary: A command line calendar that displays holidays and user-defined events. Name: pal Version: 0.4.3 Release: 1 Copyright: GPL Group: Applications/Productivity Url: http://palcal.sourceforge.net/ Source: %{name}-%{version}.tgz BuildRoot: /var/tmp/%{name}-buildroot %description pal is a command line calendar that displays holidays and user-defined events that are specified in text files. %define debug_package %{nil} %prep %setup -q %build cd src make OPT="$RPM_OPT_FLAGS" %install rm -rf $RPM_BUILD_ROOT cd src make DESTDIR="$RPM_BUILD_ROOT" install-no-rm %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) /usr/bin/pal /usr/share/man/man1/pal.1.gz /usr/share/doc/pal-%{version}/* /usr/share/locale/*/*/* /usr/share/pal /etc/pal.conf %changelog * Fri Mar 19 2004 Scott Kuhl - Updated list of installed files * Mon Aug 4 2003 Scott Kuhl - Created spec file pal-0.4.3/pal.conf0000644000175000017500000001016211043370327013611 0ustar kleptogkleptog##-------------------------------------------------------------------- ## pal.conf file ## Type "man pal" for more information about this file. ## ## Comments begin with # ## ## The latest copy of a 'template' pal.conf file can be found in ## /etc/pal.conf. It describes every setting that can be changed in ## pal.conf. ## ##-------------------------------------------------------------------- ##-------------------------------------------------------------------- ## Load pal calendar files ## ## FORMAT: ## file filename (color) ## Display the events in filename on calendar and the detailed ## listing. The "(color)" part is optional. The color you select ## will be used when displaying the events in the file. "color" can ## be: black, red, green, yellow, blue, magenta, cyan, or white. ## ## file_hide filename (color) ## Display the events in filename only in the detailed listing. ## ## ## The filenames can be absolute or relative paths. ## - If a relative path is used, pal starts in ~/.pal and looks for ## the file. If no file is found, pal starts in /usr/share/pal ## and looks for the file. ## ## - If an absolute path is used, pal will only look for the file at ## the exact path given. ## ## ## CALENDAR FILE FORMAT: ## See the man page for information about the format of the pal ## calendar files. Several calendars are installed by default in ## /usr/share/pal ## # united states holidays and other events file us.pal (red) # christian events file christian.pal (magenta) # historical events file_hide history.pal # holidays in various countries file_hide world.pal # births/deaths # file_hide birth-death.pal # computer-related events # file_hide computer.pal # music events # file_hide music.pal # australian events # file_hide australia.pal # lord of the rings events # file_hide lotr.pal # pagan events # file_hide pagan.pal ##-------------------------------------------------------------------- ## Default color for events. Unless you change it, it will be "blue" # event_color blue ##-------------------------------------------------------------------- ## Make weeks begin on monday # week_start_monday ##-------------------------------------------------------------------- ## Display week numbers in output # show_weeknum ##-------------------------------------------------------------------- ## Display custom date string with -r,-d,-s arguments ## Default: %a %e %b %Y ## ## See "man strftime" for what the symbols mean. Do not use time ## related items in the format string---use only ones that are date ## related. # date_fmt %a %e %b %Y ##-------------------------------------------------------------------- ## Show lists of events in reverse order. # reverse_order ##-------------------------------------------------------------------- ## Hide the event type (shown before a ':') when listing events. The ## event type is defined at the top of the file that the event is ## found in. # hide_event_type ##-------------------------------------------------------------------- ## Show calendar on bottom (below reminders) # cal_on_bottom ##-------------------------------------------------------------------- ## Don't use columns when displaying the calendar # no_columns ##-------------------------------------------------------------------- ## Show lists of events in a more compact form (no spaces between ## days) # compact_list ##-------------------------------------------------------------------- ## Date format used when compact_list is used ## Default: %m/%d/%Y ## ## The default writes the date in the American format. Users in other ## countries might prefer using %d/%m/%Y # compact_date_fmt %m/%d/%Y ##-------------------------------------------------------------------- ## If you get tired of always using -r, you can set the default value ## for -r here. Note: Remember that this will affect what is ## displayed when -d and -s are used too. ## Default: 0 ## ## Use the same thing thing after default_range that you use with -r. ## For example, if you always want to use '-r 1-2', use 'default_range ## 1-2'. This value can be overridden by using -r at run-time. # default_range 1-2 pal-0.4.3/share/0000755000175000017500000000000011043370327013270 5ustar kleptogkleptogpal-0.4.3/share/christian.pal0000644000175000017500000000124611043370327015755 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # CC Christian 00000106 Epiphany 00001018 Feast Day of St. Luke 00001206 St. Nicholas' Day 00001225 Christmas Easter-047 Shrove Tuesday / Mardi Gras Easter-046 Ash Wednesday (First day of Lent) Easter-007 Palm Sunday Easter-003 Maundy Thursday Easter-002 Good Friday Easter Easter Sunday Easter+035 Rogation Sunday Easter+039 Ascension Day Easter+049 Pentecost Easter+056 Trinity Sunday Easter+060 Corpus Christi pal-0.4.3/share/history.pal0000644000175000017500000006354711043370327015506 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # HH History 00000101 Anniversary of the Triumph of the Revolution in Cuba 00000101 Castro expels Cuban President Batista, 1959 00000101 Churchill delivers his "Iron Curtain" speech, 1947 00000101 First Rose Bowl; Michigan 49 - Stanford 0, 1902 00000104 Quadrantid meteor shower (look north) 00000105 -50 degrees F, Strawberry UT, 1913 00000105 The FCC hears the first demonstration of FM radio, 1940 00000105 Twelfth night 00000108 Battle of New Orleans, 1815 00000109 Plough Monday 00000110 First meeting of United Nations General Assembly in London, 1946 00000110 Thomas Paine's Common Sense published, 1776 00000111 Anniversary of the Peoples Republic of Albania 00000111 De Hostos' Birthday in Puerto Rico 00000111 Milk delivered in bottles for the first time, 1878 00000111 Prithvi Jayanti in Nepal 00000111 Surgeon General condemned cigarettes, 1964 00000111 The Whiskey-A-Go-Go opens on Sunset Boulevard in Los Angeles, 1963 00000114 Julian Calendar New Year's Day 00000114 The first "Be-In" is held in Golden Gate Park, 1967 00000116 Prohibition begins, 1920 00000120 St. Agnes Eve (Ah, bitter chill it was...) 00000124 Eskimo Pie patented by Christian Nelson, 1922 00000124 Gold discovered in California at Sutter's Mill, 1848 00000124 A B-52 bomber carrying two 24 megaton bombs crashes at Goldsboro, North Carolina; 5 of 6 safety devices failed on one of them, 1961 00000126 Sydney, New South Wales Australias settled, 1788 00000127 Grissom, White and Chaffe burned to death in Apollo 1, 1967 00000127 Vietnam War cease-fire signed, 1973 00000128 First ski tow, Woodstock VT, 1914 00000128 Space Shuttle Challenger (51-L) explodes 74 seconds after liftoff killing Scobee, Smith, McNair, Resnick, Jarvis, Onizuka and McAuliffe, 1986 00000130 Mohandas Gandhi assassinated in New Delhi by Hindu fanatic, 1948 00000130 Tet Offensive, 1968 00000131 "Ham" the chimpanzee soars into space aboard Mercury-Redstone 2, 1961 00000131 Explorer I launched, 1958. Van Allen Belt discovered 00000131 Irving Langmuir, 1881, invented tungsten filament lamp 00000201 Space Shuttle Columbia (STS-107) disintegrates 15 minutes before landing, 2003 00000201 First TV soap: Secret Storm, 1954 00000201 Forces led by Khomeini take over Iran, 1979 00000204 Cybernet inaugurated, 1969 00000204 Patricia Hearst kidnaped by Symbionese Liberation Army, 1974 00000208 1963 Revolution Anniversary in Iraq 00000209 -51 degrees F, Vanderbilt MI, 1934 00000212 US President Abraham Lincoln's real birthday (born 1809) 00000212 Santa Barbara oil leak, 1969 00000214 Bombing of Dresden, 1945 00000215 Chicago Seven convicted, 1970 00000216 Nylon patented, 1937 00000216 Stephen Decatur burns US frigate in Tripoli, 1804 00000218 Pluto discovered by Clyde Tombaugh, Lowell Observatory, AZ, 1930 00000219 US Marines land on Iwo Jima, 1945 00000220 John Glenn orbits the Earth 3 times, 1962 00000221 Battle of Verdun begins, 1916 1M casualties 00000221 First telephone directory, New Haven, Connecticut, 1878 00000221 Malcom X shot to death in Harlem, 1965 00000223 Lt. Calley confesses, implicates Cpt. Medina, 1971 00000224 Impeachment proceedings against Andrew Johnson begin, 1868 00000227 The Lionheart crowned, 1189 00000228 The "French Connection" drug bust occurs in Marseilles, 1972 00000229 French and Indian raid on Deerfield MA, 1704 00000301 Sarah Goode, Sarah Osborne, and Tituba arrested for witchcraft in Salem, Massachusetts, 1692 00000304 First meeting of Congress, 1789, in N.Y.C. 00000306 Hindenburg explodes and burns upon landing at Lakehurst, NJ, 1939 00000313 "Striptease" introduced, Paris, 1894 00000314 Teddy Roosevelt excludes Japanese laborers from continental US, 1907 00000315 Buzzards return to Hinckley OH 00000315 France assumes protectorate over Vietnam, 1874 00000315 Watts, Los Angeles, riots kill two, injure 25, 1966 00000315 Ides of March. Gaius Julius Ceasar assassinated by senators, including adoptive son Marcus Junius Brutus Caepio, 44BC 00000316 First liquid-fuel-powered rocket flight, 1926 00000316 MyLai Massacre; 300 non-combatant villagers killed by US infantrymen 00000316 Robert Goddard launches first liquid-fueled rocket, Auburn MA, 1926 00000317 Vanguard I launched, 1958. Earth proved pear-shaped 00000318 Aleksei Leonov performs first spacewalk, 1965 00000319 Swallows return to Capistrano 00000320 Radio Caroline, the original British pirate radio station, sinks, 1980 00000324 Construction of New York subway system begins, 1900 00000325 Triangle Shirt Waist Fire, 1911 00000326 Popeye statue unveiled, Crystal City TX Spinach Festival, 1937 00000327 Khrushchev becomes Premier of Soviet Union, 1958 00000328 First reaction thrust motor demonstration, 1883 00000328 Three Mile Island releases radioactive gas, 1979 00000329 Swedish settled Christiana (Wilmington) DE, 1638 00000330 Alaska purchased from Russia for $7.2 million, 1867 00000330 Five rings around Uranus discovered, 1977 00000330 Pencil with eraser patented, 1858 00000401 People of superb intelligence, savoir-faire, etc. born this day. 00000404 Martin Luther King assassinated in Memphis, Tennessee, 1968 00000404 NATO Established, 1949 00000406 Joseph Smith founds Mormon Church, 1830 00000407 Albert Hofmann synthesizes LSD in Switzerland, 1943 00000407 Alewives run, Cape Cod 00000408 Matthew Flinders and Nicolas Baudin meet in Encounter Bay, 1802 00000409 Lee surrenders to Grant at Appomattox Courthouse, 1865 00000412 Confederate troops fire first shots of Civil War at Ft Sumter, 1861 00000412 Yuri Gagarin becomes the first man in space, 1961 00000412 Space Shuttle Columbia launched, 1981 00000413 Laotian New Year (3 days) in Laos 00000414 US President Abraham Lincoln shot in Ford's Theatre by John Wilkes Booth, 1865 00000414 Titanic hits iceberg and sinks, 1912 00000415 US President Abraham Lincoln dies, 1865 00000415 Ray Kroc opens first McDonalds in Des Plaines, IL, 1955 00000416 Lincoln shot in Ford's Theatre by John Wilkes Booth, 1865 00000417 Bay of Pigs invasion crushed by Castro forces, 1961 00000418 Einstein's Death, 1955 00000418 First Laundromat opens, Fort Worth Texas, 1934 00000418 San Francisco earthquake, 1906 00000419 Landing of the "33" in Uruguay 00000419 Warsaw Ghetto uprising, 1943 00000420 Supreme Court unanimously rules in favor of busing, 1971 00000421 Lyrid meteor shower 00000422 Vladimir Ilich Ulyanov, called Lenin, Russian political leader, born in Simbirsk, 1870 00000423 Hank Aaron hits his first home run, 1954 00000426 William Shakespeare baptized in Stratford-on-Avon, England, 1564, birthdate less certain 00000427 Magellan killed in Philippines, 1521 00000429 Zipper patented by Gideon Sindback, 1913 00000501 Beltaine; Feast of the god Bel, sun god 00000503 Anti-war protest disrupts business in Washington, 1971 00000504 Four Kent State students are shot down by the National Guard, 1970 00000505 John Scopes arrested for teaching evolution, Dayton, TN, 1925 00000507 Germany surrenders after WWII, 1945 00000508 US institutes mining of Haiphong Harbor, 1972 00000509 94 degrees, New York, 1979 00000510 Germany invades Low Countries, 1940 00000510 Nazi bookburning, 1933 00000514 Beginning of Lewis and Clark Expedition, 1804 00000514 Nation of Israel proclaimed, 1948 00000515 Asylum for Inebriates founded, Binghamton NY, 1854 00000517 24" rain in 11 hours, Pearl River, S. China, 1982 00000517 Six SLA members killed in televised gun fight, 1974 00000518 Battle of Las Piedras in Uruguay 00000518 Napoleon crowned Emperor, 1804 00000521 Battle of Iquique in Chile 00000521 US explodes first hydrogen bomb, 1956 00000522 US Civil War ends, 1865 00000523 Israeli raid into Argentina to capture Adolf Eichmann, 1960 00000523 Federal Republic of Germany founded, 1949 00000524 Battle of Pinchincha in Ecuador 00000525 Successful test of the limelight in Purfleet, England, 1830 00000526 Congress sets first immigration quotas, 1924 00000527 Golden Gate Bridge opens, 1937 00000529 Edmund Hillary and Tenzing Norkay climb Mt. Everest, 1953 00000529 First food stamps issued, 1961 00000530 US Marines sent to Nicaragua, 1912 00000602 Native Americans "granted" citizenship, 1924 00000603 Last Star Trek episode first aired ("Turnabout Intruder"), 1969 00000603 A 46-cent computer chip fails, causing the mistaken detection of a Soviet missile attack by the NORAD system. About a 100 B-52 bombers were readied for take off along with the President's airborne command post before the error is detected, 1980 00000605 Robert Kennedy assassinated, 1968 00000605 US leaves the Gold Standard, 1933 00000606 First drive-in movie, 1933 00000606 Normandy landing, 1944 00000610 Death of Alexander the Great, 323 B.C. 00000610 Denver police tear gas Jethro Tull and 2000 fans at Red Rocks, 1971 00000611 Greeks seize Troy, 1184BC 00000613 Pioneer 10 flies past Neptune's orbit, and becomes the first human artifact to travel beyond the orbits of all known planets, 1983 00000614 Sandpaper invented by I. Fischer, Jr., 1834 00000615 Ben Franklin's kite experiment, 1752 00000615 Magna Carta signed, 1215 00000615 Series of photographs by Edward Muggeridge prove to Leland Stanford that all the hooves of a horse are off the ground during the gallop, 1878 00000616 "The Blues Brothers" premieres in Chicago, 1980 00000617 China explodes its first Hydrogen bomb, 1967 00000617 Watergate Democratic National Committee break-in, 1972 00000619 Julius and Ethel Rosenberg are executed in Sing-Sing prison, 1953 00000619 Lizzie Bordon acquitted, 1893 00000620 Victoria crowned, 1837 00000621 Berlin airlift begins, 1948 00000621 Sun rises over Heelstone at Stonehenge 00000622 Civil rights workers disappear in Mississippi, 1964 00000623 Slavery abolished in England, 1772 00000624 Senate repeals Gulf of Tonkin resolution, 1970 00000625 Custer's Last Stand at Little Big Horn, 1876 00000625 North Korea invades South Korea, 1950 00000626 Battle of Gettysburg, 1863 00000626 St. Lawrence Seaway dedicated by Eisenhower & Queen Elizabeth II, 1959 00000627 100 degrees, Fort Yukon, 1915 00000627 Bill Graham closes the Fillmore East, 1971 00000628 Supreme Court decides in favor of Alan Bakke, 1978 00000630 "That" explosion in Siberia, 1908 00000630 China and Soviet Union announce split over ideology, 1960 00000701 Battle of Gettysburg begins, 1863 00000703 Dog days begin 00000704 Battles of Vicksburg and Gettysburg won by Union forces, 1863 00000704 Cloudy, 76 degrees, Philadelphia PA, 1776 00000704 New York abstains on Declaration of Independence vote, 1776 00000704 Thoreau enters woods, 1845 00000706 First `talkie' (talking motion picture) premiere in New York, 1928 00000706 Lawrence of Arabia captures Aqaba, 1917 00000707 First radio broadcast of "Dragnet", 1949 00000708 First public reading of the Declaration of Independence, 1776 00000708 Liberty Bell cracks while being rung at funeral of John Marshall, 1835 00000709 10-hour working day set by law, NH, 1847 00000710 134 degrees in Death Valley, 1913 00000712 Minimum wages established: 40 cents/hour, 1933 00000713 Women first compete in Olympic games, 1908 00000716 Detonation of the first atomic bomb at Alamagordo, NM, 1945 00000717 Disneyland opens, 1955 00000718 Ty Cobb gets 4000th base hit, 1927 00000719 Five Massachusetts women executed for witchcraft, 1692 00000720 Armstrong and Aldrin land on moon, 1969 00000721 First Train Robbery, Jesse James gets $3000 near Adair, Iowa, 1873 00000721 Vietnam divided at 17th parallel, 1954 00000723 Ice cream cone introduced, St. Louis MO, 1904 00000724 Scopes Monkey Trial, 1925 00000728 Potato introduced in Europe by Sir Thomas Harriot, 1586 00000728 B-25 hit 79th floor of Empire State Building, 1945 00000730 "In God We Trust" made US motto, 1956 00000731 Harry S. Truman dedicates N.Y. Int'l Airport @ Idlewild Field, 1948, later JFK 00000801 Lughnasa; Feast of the god Lugh, a 30 day Celtic feast centers on this day 00000803 Columbus sets sail for Cathay, 1492 00000803 First ICBM (P-7) test (5T of iron is launched to Kamchatka), 1957 00000803 USS Nautilus crosses under north polar ice cap, 1958 00000804 Axe murder of Andrew and Abbey Borden, 1892 00000804 Bombing of N. Vietnam begins, 1964 00000804 Britain declares war on Germany starting World War I, 1914 00000806 Atomic bomb dropped on Hiroshima, 1945 00000806 Caricom in Barbados 00000806 Cy Young pitches first game, 1890 00000808 Atomic bomb dropped on Nagasaki, 1945 00000808 Montenegro declares war on Germany, 1914 00000808 Richard Nixon resigns the US presidency, 1974 00000808 The Great Train Robbery -- $7,368,000, 1963 00000809 Helter Skelter... the Charles Manson murders take place, 1969 00000809 Persia defeats Spartan King Leonidas at Thermopylae, 480 BC 00000809 US/Canada border defined in the Webster-Ashburton Treaty, 1842 00000810 Chicago incorporated as a village of 300 people, 1833 00000810 US and Panama agree to transfer the canal in the year 2000, 1977 00000811 Dog days end 00000811 France Ends War in Indochina, 1954 00000811 Perseid meteor shower (look north; three days) 00000812 First test flight of Space Shuttle "Enterprise" from 747, 1977 00000812 Last US ground troops out of Vietnam, 1972 00000813 Berlin wall erected, 1961 00000813 Li'l Abner debut, 1934 00000814 Social Security begins in U.S., 1935 00000815 Gandhi's movement obtains independence for Pakistan and India, 1947 00000815 Hurricane hits Plymouth Plantation, 1635 00000816 Roller Coaster patented, 1898 00000817 First public bath opened in N.Y., 1891 00000818 Anti-Cigarette League of America formed 00000819 Air Force cargo plane snares payload from Discoverer 14 spy satellite, marking start of practical military reconnaissance from space, 1960 00000819 Gail Borden patents condensed milk, 1856 00000822 Death of King Richard III, 1485, Last of the Plantagenets 00000822 Joe Walker sets X-15 all time altitude mark (67 miles), 1963 00000822 St. Columbia reports seeing monster in Loch Ness, 565 00000823 Sacco and Vanzetti executed, 1927 00000824 "Alice's Restaurant" premieres in New York and Los Angeles, 1969 00000824 -126.9 F at Vostok, Antarctica, 1960 00000824 British troops burn Washington, 1814 00000825 First reaction thrust motor design, 1898 00000825 Gen. DeGaulle leads French forces into Paris, 1944 00000826 19th amendment of US constitution gives women the right to vote, 1920 00000827 "Tarzan of the Apes" published, 1912 00000827 Krakatoa, Java explodes with a force of 1,300 megatons, 1883 00000828 Martin Luther King leads over 200K in civil rights rally in Washington, DC, 1963 00000829 Star in Cygnus goes nova and becomes 4th brightest in sky, 1975; Nova Cygni 1975. 00000829 Hurricane Katrina hits Louisiana & Mississippi, 2005 00000830 75 cents a pound tariff set on opium, 1842 00000830 Japan Stationery Co. sells first felt-tipped pen, 1960 00000830 St. Rose of Lima in Peru 00000830 Washington-to-Moscow hot line connected, 1963 00000831 269 people killed after Korean Airlines 747 shot down by USSR, 1983 00000831 Mary Anne Nichols becomes Jack the Ripper's first victim, 1888 00000831 Non-aggression pact signed by USSR and Afghanistan, 1926 00000901 Bobby Fischer defeats Boris Spassky in World Chess Match, 1972 00000901 Joshua A. Norton proclaims himself 'Emperor Norton I', 1859 00000902 Great Britain adopts Gregorian Calendar, 1752 00000902 Japan signs unconditional surrender on US battleship `Missouri', 1945 00000903 King Richard ``the Lionheart" of Aquitaine and England crowned, 1189 00000903 Anniversary of the Founding of the Republic in San Marino 00000905 US President Kennedy orders resumption of underground nuclear tests, 1961 00000905 The first Continental Congress was convened in Philadelphia, 1774 00000906 149 Pilgrims set forth from England aboard the Mayflower, 1620 00000906 US President McKinley shot, 1901 00000906 Somhlolo in Swaziland 00000908 Star Trek debuts on NBC (1966) with "The Man Trap" 00000908 Jack the Ripper kills again, Annie Chapman is second victim, 1888 00000908 US President Ford pardons Richard M. Nixon, 1974 00000909 California becomes the 31st state of the USA, 1850 00000909 United Colonies is renamed the United States, 1776 00000910 Mountain Meadows Massacre. Mormons kill Gentile wagon train, 1857 00000911 Terrorist attacks on World Trade Center (New York City) and Pentagon (Virginia), 2001 00000912 German paratroopers rescue Mussolini from captivity in Rome, 1943 00000912 Germany annexes Sudentenland, 1938 00000913 58 C (136.4 F) measured at el Azizia, Libya, 1922 00000913 British defeat the French at Plains of Abraham near Quebec City, 1788 00000913 Building of Hadrian's Wall begun, 122 00000913 Chiang Kai-Shek becomes president of China, 1943 00000914 Benjamin Franklin is sent to France as an American minister, 1778 00000914 Salem, Massachusetts, is founded, 1629 00000914 The US Selective Service Act establishes the first peacetime draft, 1940 00000915 Soviet Premier Nikita Khrushchev begins his 13 day tour of the US, 1959 00000915 The US Foreign Affairs Dept. becomes the U.S. State Department, 1789 00000916 The village of Shawmut, Massachusetts, becomes the city of Boston, 1630 00000917 Battle of Antietam, 1862 00000918 Victory of Uprona in Burundi 00000919 New Zealand women get the right to vote, 1893 00000920 Equal Rights Party nominates Belva Lockwood for US President, 1884 00000920 First meeting of the American Association for the Advancement of Science, 1848 00000920 First meeting of the US National Research Council, 1916 00000920 Magellan leaves Spain on the first Round the World passage, 1519 00000920 The Roxy Theater opens in Hollywood, 1973 00000922 US President Lincoln issues the Emancipation Proclamation, 1862 00000922 Special prosecutor Leon Jeworski subpoenas US President Nixon, 1974 00000922 The first Soviet atomic bomb explodes, 1949 00000923 Philippine President Ferdinand Marcos declares martial law, 1972 00000923 The New York Knickerbockers becomes the first US Baseball club, 1845 00000923 US Vice President Nixon denies campaign fund fraud with his "Checkers" speech, 1952 00000925 Sandra Day O'Connor becomes first woman on US Supreme Court, 1981 00000927 The first passenger was hauled in a locomotive in England, 1825 00000928 "Pilgrim's Progress" published, 1678 00000928 A Greek soldier runs 26+ miles after the Persian defeat at Marathon, 490BC 00000930 Red Jack kills 2, Elizabeth Stride (#3) and Catherine Eddowes (#4), 1888 00000930 The first tooth is extracted under anesthesia in Charleston, Mass, 1846 00000930 The verdicts of the Nuremberg trials are announced, 1946 00001001 NASA officially begins operations, 1958 00001002 Thurgood Marshall sworn as the first black Supreme Court Justice, 1967 00001004 Crimean war begins, 1853 00001004 Sputnik I, world's first orbiting satellite launched, 1957 00001006 Antioch College is the first public school to admit men and women, 1853 00001006 Egyptian President Anwar Sadat is assassinated in Cairo, 1981 00001006 Israel is attacked by the alliance of Egypt and Syria, 1973 00001007 Foundation of the German Democratic Republic (GDR or DDR), 1949 00001007 Georgia Tech. beats Cumberland Univ. 222-0, 1916 00001007 Maryland Governor Marvin Mandel sent to prison on fraud charges, 1977 00001007 Mother Teresa of Calcutta awarded the Nobel Peace Prize, 1979 00001007 Police stop Wilbur Mills car, Fanne Fox jumps into water, 1974 00001008 Great Chicago Fire, 1871 00001009 First two-way telephone conversation, 1876 00001010 Beginning of the Wars for Independence in Cuba 00001010 Foundation of the Workers Party in North Korea 00001010 Spiro T. Agnew resigns as Vice-President due to income tax fraud, 1973 00001011 "Saturday Night Live" premiers on NBC-TV, 1975 00001011 The Gang of Four are arrested in Peking, 1976 00001011 The first steam powered ferry ran between New York and Hoboken, 1811 00001011 The second Vatican Ecumenical Council opens in Rome, 1962 00001012 Bahama Natives discover Columbus of Europe lost on their shores, 1492 00001012 Khrushchev pounds his desk with shoe during a speech to the UN, 1960 00001012 Man O'War's last race, 1920 00001013 Italy declares war on Germany, 1943 00001013 US Navy born, 1775, authorized by the Second Continental Congress 00001014 Battle of Hastings won by William the Conqueror and the Normans, 1066 00001014 Chuck Yeager breaks sound barrier, 1947 00001015 First draft card burned, 1965 00001018 Boston Shoemakers form first US labor org., 1648 00001018 Soviets announce their probe took photos of the Moon's far side, 1959 00001019 Mao Tse-tung establishes the People's Republic of China, 1949 00001019 Napoleon's beaten army begins the long retreat from Moscow, 1812 00001020 "Saturday Night Massacre", 1973 00001020 OPEC embargo, 1973 00001021 Edison makes the first practical incandescent lamp, 1879 00001021 Guggenheim Museum opens, 1959 00001023 Battle of Leyte Gulf begins, 1944 00001023 Swallows leave Capistrano 00001023 South African troops invade Angola in support of UNITA and FNLA, 1975 00001025 The UN removes Taiwan and admits the People's Republic of China, 1971 00001026 UN's World Health Organization declares smallpox eradicated, 1978 00001027 New York's Boss Tweed is arrested on fraud charges, 1871 00001027 The first New York Subway is opened, 1904 00001028 Columbus discovers Cuba, 1492 00001028 Constantine's army defeats forces of Maxentius at Mulvian Bridge, 312 00001028 Harvard was founded in Massachusetts, 1636 00001028 Statue of Liberty was dedicated on Bedloe's Island, 1886 00001029 Stock Market Crash, 1929 00001030 Orson Welles' "War of the Worlds" broadcast, 1938 00001031 Luther nails 95 Theses to door of Castle Church, Wittenberg, 1517 00001101 Austria-Hungary become two separate nations, 1918 00001101 Puerto Rican nationalists try to kill Truman at the Blair House, 1950 00001102 Luftwaffe completes 57 consecutive nights of bombing of London, 1940 00001102 Two Frenchmen make the first free hot air balloon flight, 1783 00001103 Beef rises to 3 cents a pound, IL, 1837 00001103 Linus Pauling wins Nobel Chemistry Prize, 1954 00001103 Sputnik II launched, 1957, bearing space dog Laika 00001104 Iranian militants seize US embassy personnel in Teheran, 1979 00001104 Soviet forces crush the anti-communist revolt in Hungary, 1956 00001105 Guy Fawkes' Plot, 1605 00001107 Abolitionist newspaperman Elijah P. Lovejoy murdered by mob, 1837 00001107 Lewis and Clark Expedition in sight of the Pacific Ocean, 1805 00001109 Blackout of New York, New England, and Eastern Canada, 1965 00001109 Giant panda discovered (?!), China, 1927 00001109 Jack the Ripper kills fifth and final victim, Jane Kelly, 1888 00001109 Margaret Sanger forms American Birth Control League, 1921 00001109 Roosevelt establishes the Civil Works Administration, 1933 00001110 41 Women arrested in suffragette demonstrations near White House, 1917 00001110 Cpt. Wirz, commandant of Andersonville Prison hanged, 1865 00001110 Henry Stanley asks David Livingston, "Dr. Livingston, I presume?", 1871 00001111 Washington becomes the 42nd state, 1889 00001112 Dr. Sun Yat-sen's Birthday in Taiwan 00001112 US first exports oil to Europe, 1861 00001114 Quarter Pounder price raised from $0.53 to $0.55 in violation of Nixon price controls (but okayed by Price Commission after formal request from McDonald's), 1971 00001115 Niagara Falls power plant startup, 1896 00001115 Space Shuttle Buran launched, 1988 00001116 Opening of the Suez Canal, 1869 00001117 46,000 meteoroids fall over AZ in 20 minutes, 1966 00001117 Richard Nixon says "I am not a crook.", 1973 00001118 First hydrogen bomb blasts Enewetok, 1952 00001118 Local standard time zones established for US, 1883 00001119 Gettysburg Address delivered, 1863 00001121 Announcement of 18 1/2 minute gap on Watergate tape, 1973 00001122 Kennedy shot in Dallas, Texas by Lee Harvey Oswald, 1963 00001123 First broadcast of Dr. Who (longest running TV series), 1963 00001124 Lee Harvey Oswald killed by Jack Ruby, 1963 00001125 Alfred Nobel invents dynamite, 1867 00001127 Alfred Nobel establishes Nobel Prize, 1895 00001127 Friction match invented, England, 1826 00001127 Hoosac Railroad Tunnel completed, 1873, in NW Massachusetts 00001129 King Tut's tomb opened, 1922 00001201 First national corn-husking championship, Alleman IA, 1924 00001201 Martin Luther King Jr., leads black boycott of Montgomery buses, 1955 00001201 Rosa Parks refuses to move to back of the bus (Montgomery, AL), 1953 00001203 First neon light display, Paris, 1910 00001203 First successful human heart transplant led by Dr. Barnard, 1967 00001203 The Montreux Casino burns down during a Frank Zappa concert, 1971 00001204 Washington takes leave of his officers at Fraunce's Tavern, NYC, 1783 00001205 Phi Beta Kappa founded, 1776 00001205 The Eighteenth Amendment repealed, ending the Prohibition of alcohol, 1933 00001207 Japan bombs Pearl Harbor, 1941 00001209 Ball-bearing roller skates patented, 1884 00001210 Metric system established in France, 1799 00001210 Nobel Peace Prize awarded each year 00001212 First wireless message sent across Atlantic by Marconi, 1901 00001213 Apollo 17 leaves the moon, with "last" men to walk on moon aboard, 1972 00001213 Dartmouth College chartered, 1769 00001213 Geminid meteor shower (look south) 00001215 Argo Merchant oil spill, 1976 00001215 Bill of Rights adopted, 1791 00001215 James Naismith invents basketball, Canada, 1891 00001215 Sitting Bull shot in head while submitting to arrest, 1890 00001220 US buys ~1,000,000 sq. miles of Louisiana for ~$20/sq.mi. 00001221 Phileas Fogg completes his trip around the world in less than 80 days 00001221 Women gain the right to vote in South Australia, 1894 00001221 Women gain the right to hold political office in South Australia, 1894 00001224 KKK formed in Pulaski, Tenn, 1865 00001226 DPMA founded, 1951 00001226 Indian Ocean tsunami kills approximately 230,000 people, 2004 00001227 APT report published, 1956 00001227 Ether first used as anesthetic in childbirth, 1845 00001228 Comet Kohoutek at perihelion, 1973 00001229 Battle of Wounded knee, 1890 00001230 First Los Angeles freeway dedicated, 1940 00001231 St. Sylvester in Switzerland 00001231 Winterland closes its doors, 1978 pal-0.4.3/share/lotr.pal0000644000175000017500000000306711043370327014754 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # 00 LOTR 00000105 Fellowship enters Moria 00000109 Fellowship reaches Lorien 00000117 Passing of Gandalf 00000207 Fellowship leaves Lorien 00000217 Death of Boromir 00000220 Meriadoc & Pippin meet Treebeard 00000222 Passing of King Ellesar 00000224 Ents destroy Isengard 00000226 Aragorn takes the Paths of the Dead 00000305 Frodo & Samwise encounter Shelob 00000308 Deaths of Denethor & Theoden 00000318 Destruction of the Ring 00000329 Flowering of the Mallorn 00000404 Gandalf visits Bilbo 00000417 An unexpected party 00000423 Crowning of King Ellesar 00000519 Arwen leaves Lorian to wed King Ellesar 00000611 Sauron attacks Osgilliath 00000613 Bilbo returns to Bag End 00000623 Wedding of Ellesar & Arwen 00000704 Gandalf imprisoned by Saruman 00000724 The ring comes to Bilbo 00000726 Bilbo rescued from Wargs by Eagles 00000803 Funeral of King Theoden 00000829 Saruman enters the Shire 00000910 Gandalf escapes from Orthanc 00000914 Frodo & Bilbo's birthday 00000915 Black riders enter the Shire 00000918 Frodo and company rescued by Bombadil 00000928 Frodo wounded at Weathertop 00001005 Frodo crosses bridge of Mitheithel 00001016 Boromir reaches Rivendell 00001017 Council of Elrond 00001025 End of War of the Ring 00001116 Bilbo reaches the Lonely Mountain 00001205 Death of Smaug 00001216 Fellowship begins Quest pal-0.4.3/share/pagan.pal0000644000175000017500000000520311043370327015054 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # PA Pagan 00000102 Frigg's Distaff 00000106 Celtic day of the Three-Fold Goddess 00000110 Geraints Day 00000113 Midvintersblot 00000120 Midvintersblot 00000122 Festival of the Muses 00000125 Old Disting Feast *01L3 Upelly - old fire festival 00000131 Honoring the Valkyries 00000202 1st Cross-Quarter Day 00000202 Imbolg / Imbolc (other Celtic names) / Brighid / Oimelc 00000211 The Day the Birds Begin to Sing 00000214 Festival of Vali 00000302 Day of the Crows 00000313 Burgsonndeg - festival of rebirth of the sun and the approach of spring 00000317 Celebration of Trefuilnid Treochar (St.Patrick's day) 00000318 Sheela's Day 00000319 1st Quarter Day - Spring (Vernal) Equinox 00000320 Festival of Iduna 00000321 Ostara / Eostre (Saxon goddess of Spring) 00000430 May Eve / Walpurgisnacht (witches' Sabbath) / Walpurgis Night (after St. Walpurga) 00000501 May Day / Beltane / Bealtaine - Celtic bonfire festival 00000504 2nd Cross-Quarter Day 00000512 The Cat Parade 00000514 Midnight Sun Festival 00000518 Festival of the Horned God Cennunos 00000520 Festival of Mjollnir, Thor's Hammer 00000524 Mother's Day, in celebration of the Triple Goddes 00000620 2nd Quarter Day - Summer Solstice 00000621 Litha (Norse/Anglo-Saxon for "longest day") 00000623 St. John's Eve - European Midsummer celebration 00000801 Lugnasad / Lughnasada / Lunasa - Gaelic summer "games of Lug" (sun-god) 00000802 Lady Godiva Day 00000804 Loch mo Naire 00000805 3rd Cross-Quarter Day 00000810 Puck Faire 00000814 Day of the Burryma 00000817 Odin's Ordeal 00000823 Feast of Ilmatar 00000828 Frey Faxi 00000829 Festival of Urda 00000921 3rd Quarter Day - Fall (Autumnal) Equinox 00001008 Day of Remembrance for Erik the Red 00001009 Leif Erikson Day 00001011 Old Lady of the Trees 00001014 Winter Nights - festival celebrating the harvest 00001018 Great Horn Faire 00001024 Feast of the Spirits of the Air 00001027 Allan Apple Day 00001031 Hallowmas / Allhallowmas / Allhallows 00001101 Samhain - Celtic feast of departing Sun & new year 00001105 4th Cross-Quarter Day 00001206 Festival of Nicolas, an aspect of Odin, leader of the hunt 00001209 Yule Cleansing - The Danish fetch water for brewing the Yule-Ale 00001213 Wodan's Jag - the Wild Hunt of Odin and his Army 00001218 Festival of Epona 00001220 4th Quarter Day - Winter Solstice 00001221 Festival of Beiwe / Nertha / Alban Athuan 00001221 Yule (Norse for "wheel") - Germanic 12-day feast pal-0.4.3/share/us.pal0000644000175000017500000000207711043370327014423 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # US USA 00000101 New Year's Day 00000202 Groundhog Day 00000212 Lincoln's Birthday 00000214 Valentine's Day 00000222 Washington's Birthday (traditional) 00000229 Leap Day 00000317 St. Patrick's Day 00000401 April Fool's Day 00000415 Federal income taxes due (if weekend, they're due on Monday) 00000422 Earth Day 00000614 Flag Day 00000704 Independence Day 00001012 Columbus Day (traditional) 00001111 Veterans' Day 00001224 Christmas Eve 00001225 Christmas Day 00001231 New Year's Eve *0132 Martin Luther King's birthday *0232 President's Day *0232 Washington's birthday *0321 Daylight Saving Time begins --- move clocks forward *0521 Mother's Day *0537 Armed Forces Day *05L2 Memorial Day *0631 Father's Day *0912 Labor Day *1022 Columbus Day *1111 Daylight Saving Time ends --- move clocks back *1145 Thanksgiving Day pal-0.4.3/share/world.pal0000644000175000017500000005547311043370327015133 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # WW World Events 00000101 Independence Day in Haiti, Sudan 00000101 Universal Fraternity Day in Mozambique 00000102 Ancestry Day in Haiti 00000102 St. Berchtold's Day in Switzerland 00000103 New Year's Holiday in Scotland 00000103 Revolution Day in Upper Volta 00000104 Independence Day in Burma 00000104 Martyrs Day in Zaire 00000106 Children's Day in Uruguay 00000106 Three Kings' Day in Puerto Rico 00000107 Christmas in Ethiopia 00000107 Pioneer's Day in Liberia 00000109 Day of the Martyrs in Panama 00000111 Armed Forces Day in Liberia 00000112 Zanzibar Revolution Day in Tanzania 00000113 National Liberation Day in Togo 00000115 Arbor Day in Jordan 00000116 Martyrs Day in Benin 00000118 Revolution Day in Tunisia 00000119 Confederate Heroes Day in Texas 00000119 Ethopian Epiphany in Ethiopia 00000119 Nameday of Archbishop Makarios in Cyprus 00000120 Army Day in Mali 00000120 National Heroes Day in Guinea-Bissau *0131 Martin Luther King Day in New York *0132 Robert E. Lee's Birthday in Alabama & Mississippi *0132 Lee-Jackson Day in Virginia 00000121 Our Lady of Altagracia in Dominican Republic 00000123 Feast of St. Ildefonsus 00000123 US National Handwriting Day 00000124 Economic Liberation Day in Togo 00000126 Republic Day in India 00000130 Australia Day in Australia 00000201 Chinese New Year Holiday (3 days) in Taiwan 00000202 Candlemas 00000204 Independence Commemoration Day in Sri Lanka 00000205 Constitution Day in Mexico 00000206 New Zealand Day 00000207 Independence Day in Grenada 00000209 St. Maron's Day in Lebanon 00000210 Feast of St. Paul's Shipwreck, AD 60 00000211 National Foundation Day in Japan 00000212 Pyidaungsa Day in Burma 00000216 Makha Bucha Day in Thailand 00000218 Democracy Day in Nepal 00000218 Independence Day in The Gambia 00000223 Republic Day in Guyana 00000224 Gregorian Calendar Day 00000225 National Day in Kuwait 00000227 Independence Day in Dominican Republic 00000301 Samil Independence Movement Day in South Korea 00000301 St. David's Day, Cardiff 00000302 Peasants Day in Burma 00000302 Texas Independence day 00000302 Victory of Adowa in Ethiopia 00000303 Girl's Day in Japan 00000303 Throne Day in Morocco 00000304 Vermont Admission Day (admitted as 14th state in 1791) 00000305 Independence Day in Equatorial Guinea 00000306 Lantern Day, Bejing 00000307 (Approximate) Purim - Feast of Lots 00000308 First Annual International Women's Day, 1909 00000308 International Women's Day in U.S.S.R. 00000308 Syrian National Day in Libyan Arab Republic 00000308 Women's Day in Guinea-Bissau, Taiwan, Yemen Democratic Republic 00000308 Youth Day in Zambia 00000309 Decoration Day in Liberia 00000309 Falgun Purnima Day in Nepal 00000310 Labor Day in South Korea 00000311 Johnny Appleseed Day; anniversary of the death of John Chapman 00000312 Commonwealth Day in Swaziland 00000312 Independence Day in Mauritius 00000312 Moshoeshoe's Birthday in Lesotho 00000312 Renovation Day in Gabon 00000313 National Day in Grenada 00000316 Black Press Day; first Black newspaper founded in 1827 00000317 Evacuation Day in Suffolk County, Massachusetts 00000317 St. Patrick's Day 00000319 St. Joseph's Day in Colombia, Costa Rica, Holy See, Liechtenstein, San Marino, Spain, Venezuela 00000319 Tree Planting Day in Lestho 00000320 Independence Day in Tunsia 00000320 Youth Day in Oklahoma 00000321 Afghan New Year in Afghanistan 00000321 Juarez' Birthday in Mexico 00000322 Abolition Day in Puerto Rico 00000323 Pakistan Day in Pakistan 00000325 Greek Independence Day in Cyprus 00000325 Lady Day (a.k.a. the Feast of the Annunciation) 00000325 Maryland Day in Maryland 00000325 National Holiday in Greece *03L2 Seward's Day in Alaska 00000326 Independence Day in Bangladesh 00000326 Prince Jonah Kuhio Kalanianaole Day in Hawaii 00000327 Armed Forces Day in Burma 00000329 Death of President Barthelemy Boganda in Central African Republic 00000329 Memorial Day in Madagascar 00000331 National Day in Malta 00000401 Youth Day in Benin 00000402 Malvinas Day in Argentina 00000402 Pascua Florida Day in Florida 00000404 Ching Ming Festival in Hong Kong 00000404 Liberation Day in Hungary 00000404 National Day in Senegal 00000405 Arbor Day in South Korea 00000405 Tomb Sweeping Day in Taiwan 00000406 Chakri Memorial Day in Thailand 00000406 Victory Day in Ethiopia 00000408 Fast and Prayer Day in Liberia 00000409 Martyrs Day in Tunisia 00000411 National Heroes Day in Costa Rica 00000413 National Day in Chad 00000413 Songkron Day in Thailand 00000414 Day of the Americas in Honduras 00000415 Bengali New Year in Bangladesh *0432 Patriot's Day in Maine & Massachusetts 00000416 De Diego's Birthday (celebrated in Puerto Rico) 00000416 Holy Week (5 days) in Venezuela 00000416 Tourist Week (5 days) in Uruguay 00000417 Burmese New Year in Burma 00000418 Independence Day in Zimbabwe 00000419 Declaration of Independence in Venezuela 00000419 Republic Day in Sierra Leone 00000421 San Jacinto Day in Texas 00000422 Arbor Day in Nebraska & Delaware 00000422 Oklahoma Day in Oklahoma 00000424 Victory Day in Togo 00000424 (Approximate) Pesach - First Day of Passover - Festival of Freedom 00000425 Anzac Day in Australia, New Zealand, Tonga, Western Samoa 00000425 Liberation Day in Italy 00000425 National Flag Day in Swaziland 00000426 Confederate Memorial Day in Florida & Georgia 00000426 Union Day in Tanzania 00000427 Independence Day in Togo *04L2 Arbor Day in Wyoming *04L2 Confederate Memorial Day in Alabama & Mississippi 00000430 The Workers Day in Uruguay 00000501 Labor Day in many places 00000501 Law Day (decl. by Eisenhower) 00000501 May Day in many places 00000502 Constitution Day in Japan 00000504 Rhode Island Independence Day 00000505 Children's Day in Japan, South Korea 00000505 Coronation Day in Thailand 00000505 Liberation Day in Netherlands 00000506 Bataan Day in Philippines 00000506 (Approximate) Bank Holiday in UK 00000507 May Day in United Kingdom 00000508 Truman Day in Missouri 00000509 Liberation Day in Czechoslovakia 00000509 Victory Day in Poland, U.S.S.R. 00000510 Confederate Memorial Day in South Carolina 00000510 Mothers Day in Guatemala 00000511 Minnesota Day in Minnesota 00000514 Buddhist Holiday (Waisak 2528) in Indonesia 00000514 Independence Day (2 days) in Paraguay 00000514 Unification Day in Liberia 00000515 Kamuzu Day in Malawi 00000515 Vesak Day in Singapore, Malaysia 00000515 Visakha Bucha Day in Thailand 00000516 Discovery Day in Cayman Islands 00000517 Constitution Day in Nauru, Norway 00000518 Flag Day in Haiti 00000518 Prayer Day in Denmark 00000519 Youth and Sports Day in Turkey *0532 Memorial Day in Michigan 00000520 Mecklenburg Independence Day in North Carolina 00000520 National Day in Cameroon 00000520 Victoria Day in Canada 00000522 National Heroes Day in Sri Lanka 00000522 Declaration of the Republic of Yemen, 1990 00000523 Commonwealth Day in Jamaica, Belize 00000523 National Labor Day in Jamaica 00000524 Bermuda Day in Bermuda 00000524 Day of Slav Letters in Bulgaria 00000525 African Freedom Day in Zimbabwe 00000525 African Liberation Day in Chad, Mauritania, Zambia 00000525 Independence Day in Jordan 00000525 Memorial Day in New Mexico & Puerto Rico 00000526 (Approximate) First Day of Shavuot 00000527 (Approximate) Bank Holiday in UK 00000528 Mothers Day in Central African Republic 00000531 Pya Martyrs Day in Togo 00000531 Republic Day in South Africa 00000601 Independence Days (3 days) in Western Samoa 00000601 Madaraka Day in Kenya 00000601 Victory Day in Tunisia 00000603 Confederate Memorial Day in Kentucky & Louisiana 00000603 Labor Day in Bahamas 00000603 (Approximate) Bank Holiday in Rep. of Ireland 00000604 Emancipation Day in Tonga 00000605 Constitution Day in Denmark 00000605 Liberation Day in Seychelles 00000606 Memorial Day in South Korea 00000609 Senior Citizen's Day in Oklahoma 00000610 Camoes Day in Portugal 00000611 King Kamehameha I Day in Hawaii 00000612 Independence Day in Philippines 00000614 Flag Day 00000617 Bunker Hill Day in Suffolk County, Massachusetts 00000617 Independence Day in Iceland 00000617 National Day in Federal Republic of Germany 00000618 Evacuation Day in Egypt 00000619 Emancipation Day in Texas 00000619 Labor Day in Trinidad, Tobago 00000619 Revolution Day in Algeria 00000620 Flag Day in Argentina 00000620 West Virginia Day in West Virginia 00000622 National Sovereignty Day in Haiti 00000623 National Holiday in Luxembourg 00000624 Fisherman's Day in Madagascar, Mozambique, Somalia 00000624 Kings Day in Spain 00000624 Peasants Day in Peru 00000624 St. Jean-Baptiste Day in Quebec 00000628 Mothers Day in Central African Republic 00000629 Independence Day in Seychelles 00000629 Last Day of Ramadan* in Algeria, Oman 00000630 Day of the Army in Guatemala 00000701 Canada Day in Canada (previously Dominion Day) 00000701 Freedom Day in Suriname 00000701 Independence Day in Burundi 00000701 National Day in Rwamda 00000701 Republic Day in Ghana 00000702 National Day in Kiribati 00000704 Caribbean Day in Guyana 00000704 Constitution Day in Cayman Islands 00000704 Family Day in Lesotho 00000704 Heroes Day in Zambia 00000704 Kadooment Day in Barbados 00000704 Philippine-American Friendship Day in the Philippines 00000704 Warriors Day (2 days) in Yugoslavia 00000705 Day of Peace and Unity in Rwanda 00000705 Independence Day in Algeria, Venezuela 00000707 National Day in Malawi 00000707 Saba Saba Day in Tanzania 00000709 Independence Day in Argentina 00000710 Independence Day in Bahamas 00000711 National Holiday in the Mongolian People's Republic 00000714 Bastille Day 00000714 National Holiday in Monaco 00000715 St. Swithin's Day 00000716 Presidents Day in Botswana 00000717 Constitution Day in South Korea 00000717 Public Holiday in Botswana 00000718 Constitution Day in Uruguay 00000718 Liberation Day in Nicaragua 00000719 Martyrs Day in Burma 00000720 Independence Day in Colombia 00000721 National Holiday in Belgium 00000722 National Day in Poland 00000723 Egyptian National Day in Syrian Arab Republic 00000723 Remembrance Day in Papua, New Guinea 00000724 Pioneer Day in Utah 00000724 Simon Bolivar's Day in Ecuador, Venezuela 00000725 Constitution Day in Puerto Rico 00000725 National Rebellion Day (3 days) in Cuba 00000725 Republic Day in Tunisia 00000726 Independence Day in Liberia 00000726 National Day in Maldives 00000728 Independence Days (2 days) in Peru 00000729 Rain Day in Waynesburg, PA 00000731 Revolution Day in Congo 00000801 Discovery Day in Trinidad, Tobogo 00000801 Emancipation Day in Granada 00000801 Freedom Day in Guyana 00000801 National Day in Switzerland 00000801 National Holidays (5 days) in El Salvador 00000801 Parent's Day in Zaire 00000803 Independence Day in Jamaica, Niger 00000803 Memorial Day of Archbishop Makarios in Cyprus 00000805 (Approximate) Bank Holiday in Scotland and Northern Ireland 00000806 Bank Holiday in Australia, British Columbia, Fiji, Iceland, Ireland, Ontario 00000806 Emancipation Day in Bahamas 00000806 Independence Day in Bolivia 00000809 National Day in Singapore 00000810 Independence Day in Ecuador 00000811 Heroes Day (2 days) in Zimbabwe 00000811 Independence Day in Chad 00000813 Women's Day in Tunisia 00000814 Independence Day in Pakistan 00000814 VJ Day, 1945 00000815 Independence Day in India 00000815 Liberation Day in South Korea 00000815 National Day in Congo *0836 Admission Day in Hawaii, 1984 00000816 Bennington Battle Day in Vermont 00000816 Independence Days (3 days) in Gabon 00000816 Restoration Day in Dominican Republic 00000817 Independence Day in Indonesia 00000819 Independence Day in Afghanistan 00000820 Constitution Day in Hungary 00000823 Liberation Days (2 days) in Romania 00000824 National Flag Day in Liberia 00000825 Constitution Day in Paragual 00000825 Independence Day in Uruguay 00000826 Susan B. Anthony Day in Massachusetts 00000826 (Approximate) Bank Holiday in England and Wales 00000827 Liberation Day in Hong Kong 00000828 Heroes Day in Philippines 00000830 Huey P. Long Day in Louisiana 00000830 Victory Day in Turkey 00000831 Independence Day in Trinidad, Tobago 00000831 National Day in Malaysia 00000831 Pashtoonian Day in Afghanistan 00000903 Independence Day in Qatar 00000903 Memorial Day in Tunisia 00000906 Defense of Pakistan Day in Pakistan 00000906 Settlers Day in South Africa 00000907 Independence Day in Brazil 00000909 Admission Day in California 00000909 National Day in North Korea 00000910 Korean Thanksgiving Day (Chusuk) in South Korea 00000910 National Day in Belize 00000911 National Holiday in Chile 00000912 Defender's Day in Maryland 00000912 Revolution Day in Ethiopia 00000913 Barry Day commemorates the death of Commodore John Barry 00000915 Respect for the Aged Day in Japan 00000916 Cherokee Strip Day in Oklahoma 00000916 Independence Day in Mexico, Papua, New Guinea 00000917 National Heroes Day in Angola 00000918 Independence Day in Chile 00000919 Army Day in Chile 00000921 Independence Day in Belize 00000922 Independence Day in Mali 00000922 National Sovereignty Day in Haiti 00000924 Independence Day in Guinea-Bissau 00000924 National Day in Saudi Arabia 00000924 Republic Day in Trinidad, Tobago 00000925 Army Day in Mozambique 00000925 Referendum Day in Rwanda 00000926 National Day in Maldives, People's Democratic Yemen Republic 00000926 Revolution Anniversary Day in Yemen Arab Republic 00000928 Confucius' Day in Taiwan 00000930 Botswana Day in Botswana 00000930 First Day of Sukkot 00001001 Armed Forces Day in South Korea 00001001 Independence Day in Nigeria 00001001 Labor Day in Australia 00001001 National Liberation Day (2 days) in China 00001001 Public Holiday in Botswana 00001003 National Foundation Day in South Korea 00001003 U.N. Day in Varbados 00001003 German Reunification Day in Germany 00001004 Independence Day in Lesotho 00001006 National Sports Day in Lesotho 00001007 National Heroes Day in Jamaica 00001008 Constitution Day in U.S.S.R 00001008 Thanksgiving Day in Canada 00001009 Independence Day in Uganda 00001009 Korean Alphabet Day in South Korea 00001009 Leif Erikson Day commemorates the discovery of North America in AD 1000 00001009 Republic Day in Khmer Republic 00001010 Fiji Day in Fiji 00001010 Health-Sports Day in Japan 00001010 National Day in Taiwan 00001010 Oklahoma Historical Day in Oklahoma 00001011 Day of the Revolution in Panama 00001011 Druger Day in South Africa 00001012 Day of the Race in Argentina 00001012 Discovery Day in Gahamas 00001012 National Day in Equatorial Guinea, Spain 00001012 Our Lady Aparecida Day in Brazil 00001012 Pan American Day in Belize 00001013 St. Edward's Day - Patron saint of England 00001014 National Day in Yemen Arab Republic 00001014 Young People's Day in Zaire 00001014 (Approximate) Thanksgiving Day in Canada 00001015 Evacuation Day in Tunisia 00001016 National Boss Day 00001017 Heroes Day in Jamaica 00001017 Mother's Day in Malawi 00001020 Kenyatta Day in Kenya 00001021 Armed Forces Day in Honduras 00001021 Revolution Days (2 days) in Somalia 00001023 Chulalongkron's Day in Thailand 00001024 Independence Day in Zambia 00001024 United Nations Day 00001025 Labor Day in New Zealand 00001025 Taiwan Restoration Day in Taiwan 00001026 Agam Day in Nauru 00001026 Armed Forces Day in Benin, Rwanda 00001026 National Day in Austria 00001028 National Holiday in Greece 00001028 OHI Day in Cyprus 00001028 (Approximate) Bank Holiday in Rep. of Ireland 00001029 Republic Day in Turkey 00001031 Nevada Day in Nevada 00001101 All Saints Day 00001102 All Souls Day in Bolivia, Brazil, El Salvador, Uruguay 00001102 Memorial Day in Ecuador 00001103 Culture Day in Japan 00001103 Thanksgiving Day in Liberia 00001104 Flag Day in Panama 00001104 Will Rogers Day 00001106 Green March Day in Morocco 00001107 National Revolution Day 00001107 October Revolution Day in Hungary 00001111 Remembrance Day in Canada 00001111 Republic Day in Maldives 00001115 Dynasty Day in Belgium 00001117 Army Day in Zaire 00001118 Independence Day in Morocco 00001118 National Days (4 days) in Oman 00001119 Discovery Day in Puerto Rico 00001119 Feast Day of S.A.S. Prince Rainier in Monaco 00001120 Revolution Day in Mexico 00001121 Day of Prayer and Repentance in Federal Republic of Germany 00001122 Independence Day in Lebanon 00001123 Labor Thanksgiving Day in Japan 00001125 Independence Day in Suriname 00001128 Independence Day in Albania, Mauritania 00001129 Day of the Republic (2 days) in Yugoslavia 00001129 Goodwill Day in Liberia 00001129 Liberation Day in Albania 00001129 National Day in Burma 00001130 Independence Day in Barbados, People's Democratic Yemen Republic 00001130 National Day in Benin 00001130 National Heroes Day in Philippines 00001130 St. Andrew's Day 00001201 Independence Day in Central African Republic 00001201 World AIDS Day 00001202 National Holiday in United Arab Emirates 00001203 National Holiday in Laos 00001206 Independence Day in Finland 00001207 Delaware Day in Delaware 00001207 Independence Day in Ivory Coast, Panama 00001208 Mother's Day in Panama 00001209 Independence Day in Tanzania 00001210 Human Rights Day 00001210 Thai Constitution Day in Thailand 00001210 Wyoming Day in Wyoming 00001211 Independence Day in Upper Volta 00001212 Independence Day in Kenya 00001213 Republic Day in Malta 00001215 Statue Day in Netherlands Antilles 00001216 Constitution Day in Nepal 00001216 Day of the Covenant in South Africa 00001216 National Day in Bahrain 00001216 Victory Day in Bangladesh 00001217 National Day in Bhutan 00001218 Republic Day in Niger 00001223 Victory Day in Egypt 00001225 Children's Day in Congo 00001226 Bank Holiday in Canada, Rep. of Ireland, and UK 00001226 Boxing Day 00001226 Family Day in South Africa 00001226 St. Stephen's Day 00001227 Bank Holiday in Cayman Islands 00001227 Constitution Day in North Korea 00001227 Public Holiday in Lesotho, Zimbabwe 00001229 Civic Holidays (3 days) in Costa Rica 00001231 Bank Holiday in El Salvador, Honduras, Pakistan 00001231 Feed Yourself Day in Benin 00000421 Tiradentes in Brazil 00000425 Anniversary of the Revolution in Portugal 00000429 Greenary day in Japan 00000430 Queen's Birthday in Netherlands, Netherlands Antilles 00000501 Boy's day in Japan 00000502 King's Birthday in Lesotho 00000505 Battle of Puebla in Mexico 00000508 Buddha's Birthday in South Korea 00000508 Elections for the National Assembly in Philippines 00000514 Anniversary of the Founding of Guinean Democratic Party in Guinea 00000525 Anniversary of the Revolution of 1810 in Argentina 00000525 Revolution in the Sudan in Libyan Arab Republic 00000527 Afghanistan attains sovereignty, 1921 00000602 Corpus Christi in Paraguay *0612 Jefferson Davis's Birthday in Alabama, Mississippi, Floriday, Georgia & S. Carolina 00000604 Queen's Birthday in New Zealand 00000606 His Majesty, Yang Di-Pertuan Agong's Birthday in Malaysia 00000611 Queen's Birthday 00000612 Peace with Bolivia in Paraguay 00000613 Corrective Movement in Yemen Arab Republic 00000616 Bloomsday - Anniversary of Dublin events, 1904, in "Ulysses" 00000618 Queen's Birthday in Fiji 00000619 Artigas Birthday in Uruguay 00000622 Corrective Movement in the People's Democratic Yemen Republic 00000622 Midsummer Eve in Finland, Sweden 00000624 Battle of Carabobob in Venezuela 00000701 Eid-Ul-Fitr* (2 days) in Pakistan 00000701 Union of the Somalia Republic in Somalia 00000707 Anniversary of the P.U.N. in Equatorial Guinea 00000712 Battle of Boyne celebrated in Northern Ireland 00000712 The Twelfth in Northern Ireland 00000713 Buddhist Lent in Thailand 00000714 Anniversary of the Revolution in Iraq 00000717 July Revolution in Iraq 00000717 Munoz Rivera's Birthday (celebrated in Puerto Rico) 00000722 King's Birthday in Swaziland 00000723 Anniversary of the Revolution in Egypt 00000725 St. James, Patron Saint in Spain 00000727 Barbosa's Birthday (celebrated in Puerto Rico) 00000729 Olsok Eve in Norway to commemorate Norway's Viking King St. Olav 00000801 Founding of Asuncion in Paraguay 00000802 Our Lady of Los Angeles in Costa Rica 00000803 Massacre du Pidjiguiti in Buinea-bissau 00000807 Battle of Boyaca in Colombia 00000811 King Hussein's Accession to the Throne in Jordan 00000812 Queen's Birthday in Thailand 00000813 Proclamation of Independence in Central African Republic 00000814 Waddi Dhahab in Morocco 00000815 Founding of Ascuncion in Paraguay 00000815 Santa Maria in Malta 00000817 Anniversary of the Death of General San Martin in Argentina 00000909 Anniversary of the Socialist Revolution (2 days) in Bulgaria 00000910 Moon Festival in Taiwan 00000911 Anniversary of military coup in Chile 00000911 Ethiopian New Year in Ethiopia 00000912 Amilcar Cabral's Birthday in Guinea-Bissau 00000914 Battle of San Jacinto in Nicaragua 00000915 Foundation of Panama in Panama 00000923 Grito de Lares in Puerto Rico 00000924 Anniversary of the Third Republic in Ghana 00000924 Our Lady of Mercedes in Dominican Republic 00000927 Feast of Finding the True Cross in Ethiopia 00000929 Battle of Boqueron in Paraquay 00001002 Anniversary of Guinean Independence in Guinea 00001003 Chung Yeung Festival in Hong Kong 00001003 Francisco Morazan's Birthday in Honduras 00001005 Anniversary of Proclamation of the Republic in Portugal 00001008 Battle of Agamos in Peru 00001009 Independence of Guayaquil in Ecuador 00001017 Dessaline's Death Anniversary in Haiti 00001020 Anniversary of the 1944 Revolution in Guatemala 00001101 Feast of All Saints in Portugal 00001101 Samhain; Beginning of the Celtic year and most important holiday. 00001103 Independence from Columbia in Panama 00001103 Independence of Cuenca in Ecuador 00001106 Prophet Mohammed's Birthday in Malaysia 00001107 Anniversary of Great October Revolution in Bulgaria 00001108 Her Majesty, the Queen's Birthday in Nepal 00001110 King's Birthday in Bhutan 00001111 Angola gains independence from Portugal, 1975 00001111 Independence of Cartagena in Colombia 00001112 Prince Charles' Birthday in Fiji 00001114 King Hussein's Birthday in Jordan 00001115 Proclamation of the Republic in Brazil 00001115 Thatlouang Festival in Laos 00001116 Oklahoma Heritage Week in Oklahoma 00001117 Corrective Movement in Syrian Arab Republic 00001118 Battle of Viertieres in Haiti 00001119 Anniversary of the 1968 Coup by the Army in Mali 00001119 Garifuna Settlement in Belize 00001119 Prince of Wales Birthday in Fiji 00001122 Anniversary of Portuguese Aggression in Guinea 00001124 Anniversary of the New Regime in Zaire 00001128 Independence from Spain in Panama 00001128 Proclamation of the Republic in Chad 00001201 Anniversary of the Restoration of Independence in Portugal 00001207 Prophet Mohammed's Birthday in Fiji 00001208 Blessing of the Water in Uruguay 00001208 Our Lady of the Cacupe in Paraguay 00001210 Foundation of Worker's Party in Angola 00001223 Emperor's Birthday in Japan 00001225 Birthday of Quaid-i-Azam in Pakistan 00001226 Feast of Our Theotokos in Greece 00001229 His Majesty, the King's Birthday in Nepal 00001230 Anniversary of the Democratic Republic of Madagascar in Madagascar 00001231 Proclamation of the Republic in Congo pal-0.4.3/share/birth-death.pal0000644000175000017500000003306211043370327016165 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # BD Birth/Death 00000101 J.D. Salinger born, 1919 00000101 Paul Revere born in Boston, 1735 00000102 Isaac Asimov born in Petrovichi, Russian SFSR (now part of USSR), 1920 00000104 George Washington Carver born in Missouri, 1864 00000104 Jakob Grimm born, 1785 00000104 Wilhelm Beer born, 1797, first astronomer to map Mars 00000105 DeWitt B. Brace born, 1859, inventor of spectrophotometer 00000106 Millard Fillmore's birthday (let's party!) 00000111 Alexander Hamilton born in Nevis, British West Indies, 1757? 00000112 John Hancock born, 1737 00000112 "Long" John Baldry born in London, 1941 00000113 Horatio Alger born, 1832 00000113 Sophie Tucker born, 1884 00000113 Wilhelm Wien born, 1864, Nobel prize for blackbody radiation laws 00000114 Albert Schweitzer born, 1875 00000115 Martin Luther King, Jr. born, 1929 00000117 Benjamin Franklin born in Boston, 1706 00000119 Edgar Allan Poe born in Boston, 1809 00000119 Robert Edward Lee born in Stratford Estate, Virginia, 1807 00000120 George Burns born, 1896 00000121 Lenin died, 1924 00000121 Thomas Jonathan "Stonewall" Jackson born in Clarksburg, VA, 1824 00000121 Ethan Allen born, 1738 00000122 Sir Francis Bacon born, 1561 00000123 Joseph Hewes born, 1730 00000123 Ernst Abbe born, 1840, formulated diffraction theory 00000123 Sergei M. Eisenstein born in Riga, Latvia, 1898 00000123 Samuel Barber died, 1981 00000124 John Belushi born in Chicago, 1949 00000125 Robert Burns born, 1759 00000125 Virginia Woolf born, 1882 00000125 W. Somerset Maugham born, 1874 00000127 Samuel Gompers born, 1850 00000129 Andre the Giant died, 1993 00000130 Franklin Delano Roosevelt born in Hyde Park, New York, 1882 00000131 Jackie Robinson born, 1919 00000203 Gertrude Stein born, 1874 00000203 Paul Auster born in Newark, N.J., 1947 00000205 Alex Harvey (SAHB) born in Glasgow, Scotland, 1935 00000206 King George VI of UK dies; his daughter becomes Elizabeth II, 1952 00000207 Sinclair Lewis born, 1885 00000208 Friedleib F. Runge born, 1795, father of paper chromatography 00000208 Jules Verne born in Nantes, France, 1828 00000209 George Hartmann born, 1489, designed astrolabes, timepieces, etc. 00000210 Charles Lamb born, 1775 00000210 William Allen White born, 1868 00000211 William Henry Fox Talbot born, 1800, photographic pioneer 00000211 Thomas Edison born, 1847 00000211 Sergei M. Eisenstein died in Moscow, Russia, 1988 00000212 Abraham Lincoln born, 1809 00000212 Charles Darwin born in Shrewsbury, England, 1809 00000215 Galileo Galilei born in Pisa, Italy, 1564 00000215 Susan B. Anthony born, 1820 00000216 Pierre Bouguer born, 1698, founder of photometry 00000217 Federic Eugene Ives born, 1856, pioneer of halftone process 00000217 T. J. Watson, Sr. born, 1874 00000218 Ernst Mach born, 1838, philosopher & optics pioneer 00000219 Nicolas Copernicus born in Thorn, Poland, 1473 00000220 Ludwig Boltzmann born, 1844, atomic physics pioneer 00000221 Alexis De Rochon born, 1838, developed the spyglass 00000222 George Washington born, 1732 00000222 Pierre Jules Cesar Janssen born, 1824, found hydrogen in the sun 00000223 W.E.B. DuBois born, 1868 00000224 Wilhelm Grimm born, 1786 00000224 Winslow Homer born, 1836 00000225 Renoir born, 1841 00000226 Dominique Francois Jean Arago born, 1786; observed "Poisson's spot" cf June 21 00000227 Marian Anderson born, 1897 00000228 Michel de Mantaigne born, 1533 00000229 Herman Hollerith born, 1860 00000301 David Niven born, 1909 00000302 Dr. Seuss born, 1904 00000304 Casimir Pulaski born, 1747 00000304 Gogol dies, 1852 00000305 Joseph Stalin dies in Moscow, 1953 00000305 John Belushi dies in Los Angeles, 1982 00000306 Michelangelo Buonarroti born in Caprese, Italy, 1475 00000307 Sir John Frederick William Herschel born, 1792, astronomer 00000308 Alvan Clark born, 1804, astronomer & lens manufacturer 00000309 Howard Aiken born, 1900 00000311 Robert Treat Paine born, 1731 00000311 Vannevar Bush born, 1890 00000312 Gustav Robert Kirchhoff born, 1824, physicist 00000314 Albert Einstein born, 1879 00000314 Casey Jones born, 1864 00000314 Giovanni Virginio Schiaparelli born, 1835, astronomer; named Mars "canals" 00000315 Julius Caesar assassinated by Brutus; Ides of March, 44BC 00000315 J.J. Robert's Birthday in Liberia 00000316 George Clymer born, 1739 00000316 James Madison born, 1751 00000321 Jean Baptiste Joseph Fourier born, 1768, mathematician & physicist 00000323 Pierre Simon de Laplace born, 1749, mathematician & astronomer 00000324 Harry Houdini born, 1874 00000326 Benjamin Thompson born, 1753, Count Rumford; physicist 00000326 David Packard died, 1996; age of 83 00000327 Wilhelm Conrad Roentgen born, 1845, discoverer of X-rays 00000330 Francisco Jose de Goya born, 1746 00000330 Sean O'Casey born, 1880 00000330 Vincent Van Gogh born, 1853 00000330 Adolph Hitler comitted suicide, 1945 00000331 Rene Descartes born, 1596, mathematician & philosopher 00000331 Nikolay Vasilyevich Gogol born, 1809 00000403 Washington Irving born, 1783 00000404 Andrey Tarkovsky born, 1932 00000405 Thomas Hobbes born, 1588, philosopher 00000408 Buddha born, 563 BC 00000408 David Rittenhouse born, 1732, astronomer & mathematician 00000409 Edward Muybridge born, 1830, motion-picture pioneer 00000409 J. Presper Eckert born, 1919 00000410 Commodore Matthew Calbraith Perry born, 1794 00000410 William Booth born, 1829, founder of the Salvation Army 00000411 Edsger Wybe Dijkstra was born at Rotterdam, 1930 00000413 Samuel Beckett born in Foxrock, County Dublin, 1906 00000413 Thomas Jefferson born, 1743 00000414 Christian Huygen born, 1629, physicist & astronomer; discovered Saturn's rings 00000415 Leonardo da Vinci born, 1452 00000415 Jean Genet died in Paris, 1986 00000416 Charles (Charlie) Chaplin (Sir) born in London, 1889 00000419 Andre Rene the Giant (Roussimoff) born in Grunoble, France, 1946 00000420 Adolph Hitler born, 1889 00000422 Kant born, 1724 00000422 Lenin born, the best friend of all the children, 1870 00000423 Shakespeare born, 1564 00000428 James Monroe born, 1758 00000428 Mussolini executed, 1945 00000429 Jules Henri Poincare born, 1854, founder of topology 00000429 William Randolph Hearst born in San Francisco, 1863 00000430 Karl Friedrich Gauss born, 1777, mathematician & astronomer 00000501 Little Walter (Marion Walter Jacobs) born in Alexandria, Louisiana, 1930 00000502 Dr. Benjamin Spock born, 1903 00000509 Pinza died, 1957 00000510 Fred Astaire (Frederick Austerlitz) born in Omaha, Nebraska, 1899 00000512 Florence Nightingale born in Florence, Italy, 1820 00000513 Arthur S. Sullivan born, 1842 00000515 Mike Oldfield born in Essex, England, 1953 00000519 Ho Chi Minh born, 1890 00000521 Plato (Aristocles) born in Athens(?), 427BC 00000527 Hubert H. Humphrey born, 1911 00000528 Dionne quintuplets born, 1934 00000529 Gilbert Keith Chesterton born, 1874 00000529 John Fitzgerald Kennedy born, 1917 00000529 Patrick Henry born, 1736 00000530 Mel (Melvin Jerome) Blanc born in San Francisco, 1908 00000601 Brigham Young born, 1801 00000601 Marilyn Monroe born, 1926 00000602 Edward Elgar (Sir) born in Worcestershire, England, 1857 00000603 Franz Kafka dies in Praha, 1924 00000603 Henry James born, 1811 00000607 (Eugene Henri) Paul Gauguin born, 1848 00000607 George Bryan "Beau" Brummel born, 1778 00000607 Alan Mathison Turing died, 1954 00000608 Frank Lloyd Wright born in Richland Center, Wisconsin, 1867 00000613 Alexander the Great dies (323BC) 00000615 Edward (Edvard Hagerup) Grieg born in Bergen, Norway, 1843 00000616 Hammurabi the Great dies, Babylon, 1686 BC 00000617 M.C. Escher born, 1898 00000622 Carl Hubbell born, 1903 00000622 Meryl Streep born in Summit, New Jersey, 1949 00000622 Konrad Zuse born in Berlin, 1919 00000623 Alan Mathison Turing born, 1912 00000625 Eric Arthur Blair (a.k.a. George Orwell) born, 1903 00000627 Helen Keller born, 1880 00000703 Franz Kafka born in Vienna, 1883 00000704 Nathaniel Hawthorne born in Salem, Massachusetts, 1804 00000704 John Adams and Thomas Jefferson die on same day, 1826 00000706 John Paul Jones born, 1747 00000707 P.T. Barnum dies, 1891 00000708 Count Ferdinand von Zeppelin born, 1838 00000710 John Calvin born, 1509 00000711 John Quincy Adams born, 1767 00000712 Henry David Thoreau born, 1817 00000715 Clement Clarke Moore born, 1779, author of "A Visit from Saint Nicholas" 00000718 Brian Auger born in London, 1939 00000725 Steve Goodman born in Chicago, 1948 00000728 (Helen) Beatrix Potter born, 1866 00000729 Mussolini born, 1883 00000730 Emily Bronte born, 1818 00000730 Henry Ford born, 1863 00000801 Herman Melville born, 1819 00000803 Lenny Bruce dies of a morphine overdose, 1966 00000806 Edsger Wybe Dijkstra died after a long struggle with cancer, 2002 00000808 Dustin Hoffman born in Los Angeles, 1937 00000812 Thomas Mann's Death, 1955 00000813 Alfred Hitchcock born, 1899 00000813 Annie Oakley born, 1860 00000813 Fidel Castro born, 1927 00000815 Louis Victor de Broglie born, 1892, physicist 00000817 Mae West born, 1892 00000818 Meriwether Lewis born, 1774 00000820 Leon Trotsky assassinated, 1940 00000823 Gene Kelly born, 1912 00000827 Lyndon B. Johnson born, 1908 00000829 Oliver Wendell Holmes born, 1809, physician & father of the jurist 00000830 John W. Mauchly born, 1907 00000905 King Louis XIV of France born, 1638 00000905 Raquel Welch born, 1942 00000906 Word is received that Perry has reached the North Pole and died, 1909 00000907 James Fenimore Cooper born in Burlington, NJ, 1789 00000907 Queen Elizabeth I of England born, 1533 00000908 Richard ``the Lionheart", King of England born in Oxford, 1157 00000908 Peter Sellers born in Southsea, England, 1925 00000909 Chinese Communist Party Chairman Mao Tse-Tung dies at age 82, 1976 00000912 Jesse Owens born, 1913 00000912 Stanislaw Lem born in Lwow, Poland, 1921 00000913 Walter Reed born, 1851 00000915 Agatha Christie born in Torquay, England, 1890 00000916 Allen Funt born in Brooklyn, NY, 1914 00000918 Konstantin Eduardovich Tsiolkovsky born, 1857, father of rocket flight 00000918 Greta Garbo born, 1905 00000918 Jimi Hendrix dies from an overdose, 1970 00000919 President Garfield dies of wounds in Elberon, N.J., 1881 00000919 Tsiolkovsky died, 1935 00000920 Upton (Beall) Sinclair born, 1878 00000921 H.G. (Herbert George) Wells born in Bromley, England, 1866 00000921 Louis Joliet born, 1645 00000923 Augustus (Gaius Octavius) Caesar born in Rome, 63 BC 00000923 Euripides born in Salamis, Greece, 480 BC 00000924 F. Scott Fitzgerald born, 1896 00000926 Johnny Appleseed born, 1774 00000926 T.S. (Thomas Stearns) Eliot born in St. Louis, 1888 00000927 Thomas Nast born, 1840 00000928 Pompey (Gnaeus Pompeius Magnus) born in Rome, 106BC 00000928 Seymour Cray born, 1925 00000929 Gene Autry born, 1907 00001001 Jimmy Carter born, 1924 00001002 Aristotle dies of indigestion, 322 BC 00001002 Mohandas K. Gandhi born at Porbandar, Kathiawad, India, 1869 00001004 John V. Atanasoff born, 1903 00001005 Pablo Picasso born in Malaga, Spain, 1881 00001005 Ray Kroc (founder of McDonald's) born, 1902 00001013 Lenny Bruce born in New York City, 1925 00001014 Dwight David Eisenhower born, 1890 00001014 William Penn born in London, 1644 00001015 Virgil (Publius Vergilius Maro) born near Mantua, Italy, 70 BC 00001015 Pelham Grenville Wodehouse born, 1881 00001016 Noah Webster born, 1758 00001016 Oscar (Fingal O'Flahertie Wills) Wilde born in Dublin, 1854 00001017 Richard Mentor Johnson born, 1780, 9th V.P. of U.S. 00001021 Alfred Nobel born in Stockholm, 1833 00001027 Gerald M. Weinberg born, 1933 00001027 James Cook born, 1728 00001031 Chiang Kai-Shek born, 1887 00001031 Dale Evans born, 1912 00001101 Joseph Stalin's burial, 1961 00001102 Daniel Boone born near Reading, PA, 1734 00001104 King William III of Orange born, 1650 00001105 Roy Rogers born, 1912 00001109 Carl Sagan born, 1934 00001110 Martin Luther born in Eisleben, Germany, 1483 00001110 Soviet President Leonid Brezhnev dies at age 75, 1982 00001111 Kurt Vonnegut, Jr, born in Indianapolis, 1922 00001113 Robert Louis Stevenson born, 1850 00001113 St. Augustine of Hippo born in Numidia, Algeria, 354 00001118 Imogene Coca born, 1908 00001118 William S. Gilbert born, 1836 00001120 Robert Fitzgerald Kennedy born, 1925 00001124 Emir Kusturica born in Srajevo, Bosnia-Herzegovina, 1954 00001125 Chaucer's death (according to tradition), 1400 00001126 Charles Schulz born in Minneapolis, Minnesota, 1922 00001126 Norbert Weiner born, 1894 00001129 John Mayall born in Cheshire, England, 1933 00001130 Cleopatra died, 30 BC 00001130 Mark Twain (Samuel Clemens) born in Florida, Missouri, 1835 00001201 Woody Allen (Allen Stuart Konigsberg) born in Brooklyn, NY, 1935 00001203 John von Neumann born, 1903 00001204 Tommy Bolin dies of a heroin overdose in Miami, 1976 00001205 Walt (Walter Elias) Disney born in Chicago, 1901 00001206 Samich Laus brewing 00001208 Horace (Quintus Horatius Flaccus) born in Venosa (Italy), 65BC 00001208 James (Grover) Thurber born in Columbus, Ohio, 1894 00001210 Emily Dickinson born, 1830 00001212 E.G. Robinson born, 1893 00001214 George Washington dies, 1799 00001217 William Safire (Safir) born, 1929 00001218 Konrad Zuse died, 1995 00001219 Jean Genet born in Paris, 1910 00001220 Carl Sagan died, 1996 00001221 Benjamin Disraeli born, 1804 00001222 Giacomo Puccini born, 1858 00001222 Samuel Beckett dies in Paris, 1989 00001222 Joseph Vissarionnovich Djugashvili (Stalin) born, 1879 00001223 Joseph Smith born, 1805 00001225 Isaac Newton (Sir) born in Lincolnshire, England, 1642 00001225 Humphrey Bogart born in New York City, 1899 00001226 Charles Babbage born, 1791 pal-0.4.3/share/austria.pal0000600000175000017500000000162511043370327015432 0ustar kleptogkleptog# Collection (c) 2005-2008 by Gerfried Fuchs # Feel free to use the data herein in whatever form you like, including # but not limited to use, modify, redistribute and sublicence in any way # you like to. AT Austria 00000101 Neujahr 00000106 Heilige Dreikönige 00000214 Valentinstag 00000501 Tag der Arbeit 00000815 Mariä Himmelfahrt 00001026 Nationalfeiertag 00001101 Allerheiligen 00001208 Mariä Empfängnis 00001224 Heilig Abend 00001225 Christtag 00001226 Stefanitag 00001231 Silvester Easter-047 Faschingsdienstag Easter-046 Aschermittwoch Easter-007 Palmsonntag Easter-003 Gründonnerstag Easter-002 Karfreitag Easter Ostersonntag Easter+001 Ostermontag Easter+039 Christi Himmelfahrt Easter+050 Pfingstmontag Easter+056 Heilige Dreifaltigkeit Easter+060 Fronleichnam *03L1 Anfang Sommerzeit --- Uhren vorstellen *0521 Muttertag *0621 Vatertag *10L1 Ende Sommerzeit --- Uhren zurückstellen pal-0.4.3/share/australia.pal0000644000175000017500000000231411043370327015753 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # AU Australia # Australias 00000128 Australia Day Holiday (Australia, except NSW, Vic) 00000610 Queen's Birthday Holiday (Australia, except WA) # ACT, NSW, common 00000318 Canberra Day (ACT) *0812 Bank Holiday (ACT, NSW) *1012 Labour Day (ACT, NSW, SA) # victoria *0322 Labour Day (Vic) *1113 Melbourne Cup (Vic) # tasmania 00000211 Regatta Day (Tas) 00000227 Launceston Cup (Tas) 00000311 Eight Hours Day (Tas) 00001010 Launceston Show Day (Tas) 00001024 Hobart Show Day (Tas) 00001104 Recreation Day (N Tas) # south australia 00000520 Adelaide Cup (SA) 00001226 Proclamation Day holiday (SA) # western australia *0312 Labour Day (WA) *0612 Foundation Day (WA) 00000930 Queen's Birthday (WA) # northern territory *0512 May Day (NT) *0716 Alice Springs Show Day (NT) *0726 Tennant Creek Show Day (NT) *0736 Katherine Show Day (NT) *07L6 Darwin Show Day (NT) *0812 Picnic Day (NT) # queensland *0512 Labour Day (Qld) 00000814 RNA Show Day (Brisbane metro) pal-0.4.3/share/music.pal0000644000175000017500000002537311043370327015120 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # MM Music 00000101 Country Joe McDonald born in El Monte, California, 1942 00000103 Steven Stills born in Dallas, 1945 00000104 Jazz great Charlie Mingus dies at 57 in Cuernavaca, Mexico, 1979 00000108 Elvis Presley born, 1935 00000108 David Bowie (then David Robert Jones) born in London, 1947 00000109 James Patrick Page (Led Zeppelin) born in Middlesex, England, 1945 00000110 Blues guitarist Howlin' Wolf dies in Chicago, 1976 00000110 Jim Croce born in Philadelphia, 1943 00000110 Pat Benatar born in Long Island, 1952 00000110 Rod Stewart born in Glasgow, Scotland, 1945 00000113 Eric Clapton plays the "Rainbow Concert" in London, 1973 00000117 Led Zeppelin's first album is released, 1969 00000119 Janis Joplin born in Port Arthur, Texas, 1943 00000122 Sam Cooke born in Chicago, 1935 00000124 Warren Zevon born, 1947 00000125 Bob Dylan plays the second "Hurricane" benefit, in the Astrodome, 1978 00000127 Bobby "Blue" Bland (Robert Calvin Bland) born in Tennessee, 1930 00000127 Wolfgang Amadeus Mozart born in Salzburg, 1756 00000128 Jimi Hendrix headlines Madison Square Garden, 1970 00000130 Lightnin' Hopkins, the most-recorded blues artist ever, dies, 1982 00000131 The Grateful Dead are busted in New Orleans, 1970 00000201 RCA Victor unveils the 45 rpm record playing system, 1949 00000202 Graham Nash born in Lancashire, England, 1942 00000203 The Day The Music Died; Buddy Holly, Richie Valens, and the Big Bopper are killed in a plane crash outside Mason City, Iowa, 1959 00000207 Beatles land at JFK airport to begin first U.S. tour, 1964 00000207 Steven Stills makes the first digitally recorded rock album, 1979 00000209 Carole King (Carole Klein) born in Brooklyn, 1941 00000212 The Beatles play Carnegie Hall in New York City, 1964 00000217 Jazz great Thelonius Monk dies in Englewood, New Jersey, 1982 00000218 Yoko Ono Lennon born in Tokyo, 1933 00000219 Paul McCartney's "Give Ireland Back to the Irish" banned in Britain, 1972 00000219 William "Smokey" Robinson born in Detroit, 1940 00000220 J. Geils (J. Geils Band) born, 1946 00000220 Yes sells out Madison Square Garden...without advertising, 1974 00000223 Handel born, 1685 00000223 Johnny Winter born in Leland, Mississippi, 1944 00000225 George Harrison born in Liverpool, England, 1943 00000229 Jimmy Dorsey born, 1904 00000301 Jim Morrison is busted for obscenity in Miami, 1969 00000302 Blues guitarist Rory Gallagher born in Ballyshannon, Ireland, 1949 00000303 Buffalo Springfield formed in Los Angeles, 1966 00000304 Antonio Vivaldi born in Venice, Italy, 1678 00000307 Last Gilbert & Sullivan opera produced, 1896 00000308 Ron "Pigpen" McKernan (Grateful Dead) dies in California, 1973 00000309 Robin Trower born in London, 1945 00000313 The Allman Brothers record their live album at the Fillmore East, 1971 00000315 Sly Stone born, 1944 00000317 Paul Kantner (Jefferson Airplane) born in San Francisco, 1942 00000321 Johann Sebastian Bach born in Eisenach, 1685 00000322 Ten Years After plays their last concert, 1974 00000325 Aretha Franklin born in Detroit, 1943 00000325 Bela Bartok born in Nagyszentmiklos, 1881 00000326 Ludwig van Beethoven dies in Wien, 1827 00000326 Emerson, Lake, and Palmer record "Pictures at an Exhibition" live, 1971 00000328 Sergej Rachmaninow dies in Beverley Hills, 1943 00000329 Dr. Hook gets a group picture on the cover of "Rolling Stone", 1973 00000330 Eric Clapton born in Surrey, England, 1945 00000401 Sergej Rachmaninow born in Oneg, 1873 00000402 Marvin Gaye born in Washington, D.C., 1939 00000404 Muddy Waters (McKinley Morganfield) born in Rolling Fork, Mississippi, 1915 00000409 Paul Robeson born, 1898 00000410 Paul McCartney announces that he's quitting the Beatles, 1970 00000414 Ritchie Blackmore (Deep Purple, Rainbow) born, 1945 00000418 Yes breaks up after 13 years, 1981 00000425 Blues guitarist Albert King born, 1925 00000425 Ella Fitzgerald born, 1918 00000426 Carol Burnett born in San Antonio, Texas, 1933 00000429 "Hair" premiers on Broadway, 1968 00000501 Kate Smith born, 1909 00000503 Bob Seger born in Ann Arbor, Michigan, 1945 00000507 Johannes Brahms born in Hamburg, 1833 00000507 Tchaikowsky born, 1840 00000510 Dave Mason born in Worcester, England, 1945 00000511 Bob Marley dies in his sleep in Miami, 1981 00000512 Pink Floyd performs the first quadrophonic concert, 1977 00000518 Rick Wakeman born in West London, England, 1949 00000519 Pete Townshend born in London, 1945 00000520 The Jimi Hendrix Experience is signed by Reprise Records, 1967 00000523 Blues great Elmore James dies, 1963 00000524 Bob Dylan (Robert Zimmerman) born in Duluth, Minnesota, 1941 00000526 Al Jolson born, 1886 00000531 The Who perform the loudest concert ever -- 76,000 watts of PA, 1976 00000601 The Beatles release "Sgt. Pepper", 1967 00000606 "Rock Around The Clock" makes Billboard's #1 slot, 1955 00000606 Dee Dee Ramone died, 2002 00000607 Blind Faith debuts in concert at London's Hyde Park, 1969 00000609 Les Paul (Lester Polfus) born in Waukesha, Wisconsin, 1923 00000610 Howlin' Wolf (Chester Burnett) born in West Point, Mississippi, 1910 00000610 Judy Garland born, 1922 00000615 Harry Nilsson born in Brooklyn, 1941 00000616 The Monterey Pop festival opens, 1967 00000618 Paul McCartney born in Liverpool, England, 1942 00000621 Columbia records announces the first mass production of LP's, 1948 00000622 Todd Rundgren born in Upper Darby, Pennsylvania, 1948 00000624 Jeff Beck born in Surrey, England, 1944 00000702 Felix Pappalardi and Leslie West form Mountain, 1969 00000703 Jim Morrison dies in Paris, 1971 00000706 The Jefferson Airplane formed in San Francisco, 1965 00000707 Ringo Starr (Richard Starkey) born in Liverpool, England, 1940 00000712 Chicago DJ Steve Dahl holds "Disco Demolition" at Kamisky Park, 1979 00000714 Woodie Guthrie born, 1912 00000716 Cream forms in the U.K., 1966 00000716 Harry Chapin dies on Long Island Expressway, 1981 00000717 "Yellow Submarine" premieres at the London Pavilion, 1968 00000720 Carlos Santana born in Autlan, Mexico, 1947 00000725 Bob Dylan goes electric at the Newport Folk Festival, 1965 00000725 Crosby, Stills, Nash & Young debut at the Fillmore East, 1969 00000726 Mick Jagger born in Kent, England, 1943 00000728 Johann Sebastian Bach dies in Leipzig, 1750 00000728 The Watkins Glen "Summer Jam" opens, 1973 00000801 The Concert for Bangla Desh takes place at Madison Square Garden, 1971 00000804 John Lennon points out that "the Beatles are more popular than Jesus", 1966 00000810 Ian Anderson (Jethro Tull) born in Edinburgh, Scotland, 1947 00000813 Dan Fogelberg born in Peoria, Illinois, 1951 00000815 Beatles replace drummer Pete Best with Richard Starkey 00000815 The Beatles play Shea Stadium in New York, 1965 00000815 Woodstock Festival, Max Yasgur's farm, 1969 00000826 Jimi Hendrix gives his last performance at the Isle of Wight, 1970 00000826 Jimi Hendrix's Electric Ladyland Studios opens in New York, 1970 00000907 Keith Moon (The Who) dies in London of a drug overdose, 1978 00000908 Anton Dvorak born in Nelahozeves, Czechoslovakia, 1841 00000908 Ron "Pigpen" McKernan (Grateful Dead) born in San Bruno, California, 1945 00000914 Francis Scott Key writes words to "Star Spangled Banner", 1814 00000916 B.B. King born in Itta Bena, Mississippi, 1925 00000918 Dee Dee Ramone (Douglas Colvin) born in Fort Lee, Virginia, 1952 00000919 Simon & Garfunkel reunite to play New York's Central Park, 1981 00000920 Jim Croce dies in a plane crash, 1973 00000923 "Paul is dead" rumors sweep the country, 1969 00000923 Bruce "The Boss" Springsteen born in Freehold, New Jersey, 1949 00000925 John Bonham (Led Zeppelin) dies of alcohol poisoning, 1980 00000926 Bela Bartok dies in New York, 1945 00000926 George Gershwin born in Brooklyn, NY 00001004 Janis Joplin dies of a heroin overdose in Hollywood, 1970 00001005 Steve Miller born in Dallas, 1943 00001007 First Bandstand (later, American Bandstand) broadcast, 1957 00001009 John Lennon born in Liverpool, England, 1940 00001010 John Prine born in Maywood, Illinois, 1946 00001012 The Jimi Hendrix Experience formed in London, 1966 00001016 Bob Weir (Grateful Dead) born in San Francisco, 1947 00001017 "Hair" opens at New York's Public Theater, 1967 00001018 Chuck Berry born in San Jose, California, 1926 00001020 Three members of Lynyrd Skynyrd die in a plane crash, 1977 00001021 Jesus Christ Super Star debuted on Broadway, 1971 00001022 Franz Liszt born, 1811 00001022 Pablo Casals died in Puerto Rico, 1973 00001025 Jon Anderson (Yes) born in Lancashire, England, 1944 00001025 The Rolling Stones appear on The Ed Sullivan Show, 1964 00001029 Duane Allman dies in motorcycle crash near Macon, Georgia, 1971 00001030 Grace Slick born in Chicago, 1939 00001102 Jimi Hendrix's "Electric Ladyland" enters US charts at #1, 1968 00001102 Keith Emerson born, 1944 00001103 James Taylor and Carly Simon are married in Manhattan, 1972 00001107 Joni Mitchell (Roberta Joan Anderson) born in Alberta, Canada, 1943 00001108 Patti Page born, 1927 00001109 The first issue of "Rolling Stone" published, 1967 00001110 Greg Lake born in Bournemouth, England, 1948 00001112 Neil Young born in Toronto, 1945 00001113 Paul Simon born, 1942 00001116 Bill Ham first demonstrates his psychedelic "Light Show", 1965 00001120 Duane Allman born in Nashville, Tennessee, 1946 00001120 Joe Walsh born in Cleveland, 1947 00001124 Scott Joplin born, 1868 00001125 "The Last Waltz" concert is played by The Band at Winterland, 1976 00001125 Johann Strauss, Jr., writes `On the Beautiful Blue Danube', 1867 00001126 Cream performs their farewell concert at Royal Albert Hall, 1968 00001127 Jimi Hendrix (Johnny Allen Hendrix) born in Seattle, 1942 00001129 Pau Casals born in Vendrell, 1876 00001130 George Harrison dies at 13:30 in L.A., 2001 00001204 Frank Zappa dies in his Laurel Canyon home shortly before 18:00, 1993 00001205 Mozart dies, 1791 00001206 First sound recording made by Thomas Edison, 1877 00001206 The Rolling Stones play Altamont Speedway near San Francisco, 1969 00001207 Harry Chapin born in New York City, 1942 00001208 Jim Morrison born in Melbourne, Florida, 1943 00001208 John Lennon shot and killed in New York City, 1980 00001209 The Who's "Tommy" premieres in London, 1973 00001213 Ted Nugent, the motor city madman, born in Detroit, 1949 00001215 Thomas Edison receives patent on the phonograph, 1877 00001216 Don McLean's "American Pie" released, 1971 00001216 Ludwig von Beethoven born or christened in Bonn, Germany, 1770 00001221 Frank Zappa born in Baltimore, 1940 00001223 First G&S collaboration, Thespis, 1871 00001228 Edgar Winter born in Beaumont, Texas, 1946 00001231 Jimi Hendrix introduces the Band of Gypsies at the Fillmore East, 1969 pal-0.4.3/share/computer.pal0000644000175000017500000000660311043370327015631 0ustar kleptogkleptog# This calendar is a slightly modified version of the calendars # distributed in OpenBSD and FreeBSD. # # Original versions of these calendars can be found at: # # http://bsdcalendar.sf.net/ # http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/calendar/calendars/ # CC Computers 00000101 AT&T officially divests its local Bell companies, 1984 00000101 The Epoch (Time 0 for UNIX systems, Midnight GMT, 1970) 00000103 Apple Computer founded, 1977 00000108 American Telephone and Telegraph loses antitrust case, 1982 00000108 Herman Hollerith patents first data processing computer, 1889 00000108 Justice Dept. drops IBM suit, 1982 00000110 First CDC 1604 delivered to Navy, 1960 00000116 Set uid bit patent issued, to Dennis Ritchie, 1979 00000117 Justice Dept. begins IBM anti-trust suit, 1969 (drops it, 01/08/82) 00000124 DG Nova introduced, 1969 00000125 First U.S. meeting of ALGOL definition committee, 1958 00000126 EDVAC demonstrated, 1952 00000131 Hewlett-Packard founded, 1939 00000211 Last day of JOSS service at RAND Corp., 1966 00000214 First micro-on-a-chip patented (TI), 1978 00000215 ENIAC demonstrated, 1946 00000301 First NPL (later PL/I) report published, 1964 00000304 First Cray-1 shipped to Los Alamos 00000309 "GOTO considered harmful" (E.W. Dijkstra) published in CACM, 1968 00000314 LISP introduced, 1960 00000328 DEC announces PDP-11, 1970 00000331 Eckert-Mauchly Computer Corp. founded, Phila, 1946 00000401 Yourdon, Inc. founded, 1974 (It figures.) 00000403 IBM 701 introduced, 1953 00000404 Tandy Corp. acquires Radio Shack, 1963 (9 stores) 00000407 IBM announces System/360, 1964 00000409 ENIAC Project begun, 1943 00000428 Zilog Z-80 introduced, 1976 00000506 EDSAC demonstrated, 1949 00000501 First BASIC program run at Dartmouth, 1964 00000516 First report on SNOBOL distributed (within BTL), 1963 00000521 DEC announces PDP-8, 1965 00000522 Ethernet first described, 1973 00000527 First joint meeting of U.S. and European ALGOL definition cte., 1958 00000528 First meeting of COBOL definition cte. (eventually CODASYL), 1959 00000530 Colossus Mark II, 1944 00000602 First issue of Computerworld, 1967 00000607 Alan Mathison Turing died, 1954 00000610 First Apple II shipped, 1977 00000615 UNIVAC I delivered to the Census Bureau, 1951 00000616 First publicized programming error at Census Bureau, 1951 00000623 IBM unbundles software, 1969 00000623 Alan Mathison Turing born, 1912 00000630 First advanced degree on computer related topic: to H. Karamanian, Temple Univ., Phila, 1948, for symbolic differentiation on the ENIAC 00000708 Bell Telephone Co. formed (predecessor of AT&T), 1877 00000708 CDC incorporated, 1957 00000814 First Unix-based mallet created, 1954 00000814 IBM PC announced, 1981 00000822 CDC 6600 introduced, 1963 00000823 DEC founded, 1957 00000915 ACM founded, 1947 00000920 Harlan Herrick runs first FORTRAN program, 1954 00001002 First robotics-based CAM, 1939 00001006 First GPSS manual published, 1961 00001008 First VisiCalc prototype, 1978 00001012 Univac gives contract for SIMULA compiler to Nygaard and Dahl, 1962 00001014 British Computer Society founded, 1957 00001015 First FORTRAN Programmer's Reference Manual published, 1956 00001020 Zurich ALGOL report published, 1958 00001025 DEC announces VAX-11780, 1978 00001104 UNIVAC I program predicts Eisenhower victory based on 7% of votes, 1952 00001208 First Ph.D. awarded by Computer Science Dept, Univ. of Penna, 1965 *07L6 Sysadminday pal-0.4.3/doc/0000755000175000017500000000000011043370327012733 5ustar kleptogkleptogpal-0.4.3/doc/example.css0000644000175000017500000000446211043370327015106 0ustar kleptogkleptog/* Add the following line between and in your HTML document to use this style sheet: */ .pal-cal { width: 95%; /* width of calendar on page */ margin-left: auto; /* center calendar */ margin-right: auto; margin-bottom: 15px; /* space below each calendar */ border: 2px solid black; /* border around each calendar */ } /* formatting for the "Monday", "Tuesday", ... labels */ .pal-dayname { background-color: black; color: white; /* font color */ width: 10%; /* sets minimum width of columns in calendar */ } /* month name (on top of each calendar) */ .pal-month { background-color: #cccccc; font-weight: bold; font-size: 150%; } /* Formatting for individual days. If you wish, you can define these separately*/ .pal-today, .pal-mon, .pal-tue, .pal-wed, .pal-thu, .pal-fri, .pal-sat, .pal-sun { border: 1px solid black; height: 100px; /* minimum height of rows in calendar */ } /* additional formatting for Saturday and Sunday */ .pal-sat, .pal-sun { background-color: #eeeeee; } /* additional formatting for the current day */ .pal-today { border: 3px solid darkred; background-color: #cccccc; } /* formatting of blank days at beginning and end of calendar */ .pal-blank { border: 1px solid lightgray; } /* formatting of individual events. For example, if a calendar file in pal.conf is set up to display as red, you can change the appearance of the events in that calendar file by changing .pal-event-red. */ .pal-event-black { background-color: #000000; color: #ffffff; } .pal-event-red { background-color: #ff6666; } .pal-event-green { background-color: #66ffcc; } .pal-event-yellow { background-color: #ffff99; } .pal-event-blue { background-color: #66ccff; } .pal-event-magenta { background-color: #cc99ff; } .pal-event-cyan { background-color: #ccffff; } .pal-event-white { background-color: #cccccc; } .pal-tagline { font-size: smaller; text-align: right; } pal-0.4.3/Makefile0000644000175000017500000000004611043370327013626 0ustar kleptogkleptogpal: make -C src %: make -C src $@