Soks 1.0.2 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -50,6 +50,8 @@ end
50
50
  #Find where we are
51
51
  $SOKS_APPLICATION_DIRECTORY, this_script = File.split(File.expand_path(File.dirname(__FILE__)))
52
52
 
53
+ $IS_GEM = ($SOKS_APPLICATION_DIRECTORY =~ /\/gems\//i) ? true : false
54
+
53
55
  #Make sure we can find our libraries
54
56
  soks_library = [ File.join( $SOKS_APPLICATION_DIRECTORY,'lib') , File.join( $SOKS_APPLICATION_DIRECTORY,'lib','helpers'), File.join( $SOKS_APPLICATION_DIRECTORY,'/contrib' ) ]
55
57
  $:.push( *soks_library )
@@ -15,10 +15,11 @@ class Message
15
15
  @imap, @message_id = imap, message_id
16
16
  envelope = @imap.fetch( @message_id, 'ENVELOPE' ).first.attr['ENVELOPE']
17
17
  @subject = envelope['subject'].gsub(/^(Fw|Re):?/i,'').strip
18
- @sender_name = envelope['from'].first['name'].gsub(/@/,' at ')
18
+ @sender_name = envelope['from'].first['name']
19
19
  @date = envelope['date']
20
20
  @sender_email = envelope['from'].first['mailbox'] + ' at ' + envelope['from'].first['host']
21
21
  @sender_name = @sender_email unless @sender_name && @sender_name.size > 1
22
+ @sender_name.gsub!(/@/,' at ')
22
23
  @text = plain_text_content_from_message( message_id )
23
24
  end
24
25
 
@@ -315,8 +315,10 @@ end
315
315
  class File
316
316
 
317
317
  def self.unique_filename( path, filename )
318
- filename.tr!(' ','') # Unfortunately no spaces permitted in redcloth links
319
- return filename unless exist?( join( path, filename ) )# Leave as is, if doesn't exist
318
+ filename.tr!('\\','/') if filename =~ /^[A-Z]:\\/ # File.basename requires / rather than \ which can be a problem with file uploads
319
+ filename = File.basename( filename ) # Drop all the extra directory information
320
+ filename.gsub!(/[^A-Za-z0-9._%]/,'') # Drop anything but the basic stuff we trust
321
+ return filename unless exist?( join( path, filename ) )# Leave as is, if doesn't exist
320
322
  name, counter, extension = basename( filename, '.*'), 1, extname( filename )
321
323
  counter += 1 while exist?( join( path, "#{name}#{counter}#{extension}" ) )
322
324
  return "#{name}#{counter}#{extension}"
@@ -1,6 +1,6 @@
1
1
  #!/usr/local/bin/ruby
2
2
 
3
- SOKS_VERSION = '1.0.2'
3
+ SOKS_VERSION = '1.0.3'
4
4
 
5
5
  require 'webrick'
6
6
  require 'erb'
@@ -14,6 +14,13 @@ a {
14
14
  text-decoration:none;
15
15
  }
16
16
 
17
+ pre {
18
+ overflow: auto;
19
+ padding: 10px;
20
+ background: #eee;
21
+ border: 1px solid #ccc;
22
+ }
23
+
17
24
  a:visited {color:#888;}
18
25
 
19
26
  a:hover {
@@ -25,13 +32,9 @@ a.missing {
25
32
  color:#E00000;
26
33
  }
27
34
 
28
- td {
29
- font-size:smaller;
30
- }
31
35
 
32
36
  img {
33
37
  border-style: none;
34
- max-width: 300px;
35
38
  }
36
39
 
37
40
  #content {
@@ -213,4 +216,4 @@ div.undochange {
213
216
  .recentchanges li, .recentchanges ul {
214
217
  list-style-type: none;
215
218
  padding-left: 5px;
216
- }
219
+ }
@@ -6,6 +6,8 @@ h2. Mail2WikiHelper
6
6
 
7
7
  The mail to wiki helper periodically scans an email folder on an imap server, and copies messages across to the wiki. Each message is appended to a page with the same name as the email subject and uses the email from address as the author name.
8
8
 
9
+ p(. What about a pop server? --Bil. Should be a pretty easy rewrite to use NET::POP rather than NET::IMAP, but I unfortunately don't have any POP servers to test with. --tamc
10
+
9
11
  *NOTE* This helper ignores the contents of the authenticators array in your start.rb file.
10
12
 
11
13
  To use, put the following in your start.rb file:
@@ -14,7 +14,6 @@ This is a list of pages that will be included in the default soks distribution.
14
14
  * [[ How to hack soks ]]
15
15
  * [[ How to import a site from instiki ]]
16
16
  * [[ How to install Soks ]]
17
- * [[ How to use the keyboard shortcuts ]]
18
17
  * [[ How to use this wiki ]]
19
18
  * [[ List of changes ]]
20
19
  * [[ README ]]
@@ -36,7 +35,6 @@ This is a list of pages that will be included in the default soks distribution.
36
35
  * [[ Sidebar Page ]]
37
36
  * [[ Bug: Email adresses in page titles cause incorrect links ]]
38
37
  * [[ Bug: Memory leak ]]
39
- * [[ Pages to include in the distribution ]]
40
38
  * [[ How to import data ]]
41
39
  * [[ Tag: Include this page in the distribution ]]
42
40
  * [[ Bug: Pages that link here may not appear on restart ]]
@@ -15,6 +15,8 @@ h1. Desired Features
15
15
 
16
16
  Add what you would like to see, or email the author:
17
17
 
18
+ * Somehow move the default-helper @render_summary_of_page@ subpage markup into the view directory so that I do not have to hack @helpers/default_helpers.rb@ to change subpage style. --Bil
19
+ ** Ok I'll have a think about what can be done. I don't need to tell you of course, but you don't have to hack @helpers/default_helpers.rb@, you can just declare a subclass of AutomaticSummary that over-rides @render_summary_of_page@ in your start.rb file...
18
20
  * Move the wiki name and logo, important pages, search box, and navigation links to a top navigation, similiar to Instiki, to make the important links easier to spot.
19
21
  * Some method of avoiding edit conflicts
20
22
  ** Page locking like Instiki would be okay, but paragraph locking once editing by paragraph is added would be better.
@@ -8,14 +8,129 @@ A RSS feed of changes to this site is available [[ here => /listrss/recent chang
8
8
 
9
9
  h2. Today
10
10
 
11
+ * 17:01 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1129669262]])
12
+ * 17:00 - [[Changes to Soks-testing]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-testing?time=1129669257]])
13
+ * 17:00 - [[Changes to Soks-Stable]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-Stable?time=1129669245]])
14
+
15
+ h2. Last Sunday
16
+
17
+ * 18:18 - [[Home Page]] revised by tamc2 ([[changes => /revision/Home Page?time=1129501125]])
18
+
19
+ h2. Last Saturday
20
+
21
+ * 01:27 - [[Home Page]] revised by Luigi Maisto ([[changes => /revision/Home Page?time=1129354049]])
22
+ * 01:27 - [[mTiX homepage]] revised by Luigi Maisto ([[changes => /revision/mTiX homepage?time=1129354048]])
23
+
24
+ h2. Last Friday
25
+
26
+ * 10:11 - [[Type a title here]] revised by dom ([[changes => /revision/Type a title here?time=1129299073]])
27
+ * 10:10 - [[Page test]] revised by dom ([[changes => /revision/Page test?time=1129299053]])
28
+ * 05:01 - [[[Soks] soks-create-wiki.rb upgrade]] revised by Tom Counsell ([[changes => /revision/[Soks] soks-create-wiki.rb upgrade?time=1129280475]])
29
+
30
+ h2. Last Tuesday
31
+
32
+ * 14:17 - [[Planned Features]] revised by tamc2 ([[changes => /revision/Planned Features?time=1129054658]])
33
+ * 13:54 - [[Planned Features]] revised by Bil Kleb ([[changes => /revision/Planned Features?time=1129053294]])
34
+
35
+ h2. 10 Oct
36
+
37
+ * 07:52 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1128945172]])
38
+ * 07:52 - [[Changes to Soks-testing]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-testing?time=1128945170]])
39
+
40
+ h2. 09 Oct
41
+
42
+ * 00:01 - [[Recent changes to this site]] revised by the import script ([[changes => /revision/Recent changes to this site?time=1128830516]])
43
+
44
+ h2. 08 Oct
45
+
46
+ * 10:04 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1128780269]])
47
+
48
+ h2. 07 Oct
49
+
50
+ * 19:32 - [[Recent changes to this site]] revised by the import script ([[changes => /revision/Recent changes to this site?time=1128727966]])
51
+ * 19:11 - [[Home Page]] revised by tobi ([[changes => /revision/Home Page?time=1128726713]])
52
+ * 05:02 - [[[Soks] import script gone wild?]] revised by Tom Counsell ([[changes => /revision/[Soks] import script gone wild??time=1128675728]])
53
+ * 03:31 - [[GoDaddy.com Order Confirmation]] revised by tamc2 ([[changes => /revision/GoDaddy.com Order Confirmation?time=1128670268]])
54
+
55
+ h2. 06 Oct
56
+
57
+ * 18:29 - [[Changes to Soks-testing]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-testing?time=1128637770]])
58
+ * 16:15 - [[Site Index]] revised by the import script ([[changes => /revision/Site Index?time=1128629707]])
59
+ * 15:19 - [[Site Index]] revised by the import script ([[changes => /revision/Site Index?time=1128626398]])
60
+ * 14:44 - [[Site Index]] revised by the import script ([[changes => /revision/Site Index?time=1128624242]])
61
+ * 13:19 - [[Site Index]] revised by the import script ([[changes => /revision/Site Index?time=1128619163]])
62
+ * 12:46 - [[Site Index]] revised by the import script ([[changes => /revision/Site Index?time=1128617204]])
63
+ * 12:28 - [[Site Index]] revised by the import script ([[changes => /revision/Site Index?time=1128616084]])
64
+ * 11:28 - [[Automatic importers]] revised by tamc2 ([[changes => /revision/Automatic importers?time=1128612518]])
65
+ * 09:23 - [[Automatic importers]] revised by Bil Kleb ([[changes => /revision/Automatic importers?time=1128605035]])
66
+ * 07:18 - [[[Soks] Pathname behavior]] revised by Bil Kleb ([[changes => /revision/[Soks] Pathname behavior?time=1128597496]])
67
+ * 07:18 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1128597494]])
68
+ * 07:18 - [[Changes to Soks-Stable]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-Stable?time=1128597488]])
69
+
70
+ h2. 05 Oct
71
+
72
+ * 08:21 - [[2005 Mar 19]] revised by guest ([[changes => /revision/2005 Mar 19?time=1128514897]])
73
+ * 08:21 - [[sandbox]] revised by guest ([[changes => /revision/sandbox?time=1128514863]])
74
+
75
+ h2. 04 Oct
76
+
77
+ * 11:47 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1128440862]])
78
+ * 09:25 - [[Picture of Tom Counsell]] revised by tamc2 ([[changes => /revision/Picture of Tom Counsell?time=1128432324]])
79
+ * 09:25 - [[tamc2]] revised by tamc2 ([[changes => /revision/tamc2?time=1128432312]])
80
+ * 04:41 - [[[Soks] [Fwd: Re: [Rails] WriteBoard - Compare Revisions - How'd they do that?]]] revised by Bil Kleb ([[changes => /revision/[Soks] [Fwd: Re: [Rails] WriteBoard - Compare Revisions - How'd they do that?]?time=1128415262]])
81
+ * 02:50 - [[To Do List]] revised by tamc2 ([[changes => /revision/To Do List?time=1128408626]])
82
+
83
+ h2. 03 Oct
84
+
85
+ * 11:23 - [[sandbox]] revised by demo ([[changes => /revision/sandbox?time=1128353027]])
86
+
87
+ h2. 02 Oct
88
+
89
+ * 05:18 - [[Changes to Soks-testing]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-testing?time=1128244714]])
90
+ * 04:24 - [[Site Index]] revised by the import script ([[changes => /revision/Site Index?time=1128241461]])
91
+ * 04:20 - [[Recent changes to this site]] revised by the import script ([[changes => /revision/Recent changes to this site?time=1128241246]])
92
+ * 04:19 - [[Sidebar Page]] revised by tamc2 ([[changes => /revision/Sidebar Page?time=1128241192]])
93
+ * 03:43 - [[Picture of Bil]] revised by the import script ([[changes => /revision/Picture of Bil?time=1128239018]])
94
+
95
+ h2. 01 Oct
96
+
97
+ * 18:05 - [[View-2]] revised by ChrisBlair ([[changes => /revision/View-2?time=1128204356]])
98
+ * 18:00 - [[[Soks] File upload bug]] revised by Bil Kleb ([[changes => /revision/[Soks] File upload bug?time=1128204038]])
99
+ * 18:00 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1128204035]])
100
+ * 18:00 - [[Changes to Soks-Stable]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-Stable?time=1128204027]])
101
+ * 17:57 - [[Home Page]] revised by ChrisBlair ([[changes => /revision/Home Page?time=1128203864]])
102
+ * 17:50 - [[Bug: File Uploads broken for Internet Explorer 6.0]] revised by tamc2 ([[changes => /revision/Bug: File Uploads broken for Internet Explorer 6.0?time=1128203404]])
103
+
104
+ h2. 29 Sep
105
+
106
+ * 09:56 - [[Bug: File Uploads broken for Internet Explorer 6.0]] revised by Bil Kleb ([[changes => /revision/Bug: File Uploads broken for Internet Explorer 6.0?time=1128002174]])
107
+ * 09:45 - [[Picture of Bil]] revised by Bil.Kleb ([[changes => /revision/Picture of Bil?time=1128001527]])
108
+ * 09:41 - [[Bil Kleb]] revised by Bil Kleb ([[changes => /revision/Bil Kleb?time=1128001281]])
109
+
110
+ h2. 28 Sep
111
+
112
+ * 22:05 - [[News: Soks 1.0.2 released]] revised by Karen ([[changes => /revision/News: Soks 1.0.2 released?time=1127959535]])
113
+
114
+ h2. 27 Sep
115
+
116
+ * 08:00 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1127822443]])
117
+ * 06:21 - [[News: Soks 1.0.2 released]] revised by tamc2 ([[changes => /revision/News: Soks 1.0.2 released?time=1127816473]])
118
+ * 03:00 - [[Changes to Soks-testing]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-testing?time=1127804433]])
119
+ * 03:00 - [[Changes to Soks-Stable]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-Stable?time=1127804427]])
120
+ * 02:21 - [[Home Page]] revised by tamc ([[changes => /revision/Home Page?time=1127802078]])
121
+ * 02:06 - [[Fixed Bug: AutomaticSummary can overwrite existing pages]] revised by tamc ([[changes => /revision/Fixed Bug: AutomaticSummary can overwrite existing pages?time=1127801214]])
122
+ * 02:06 - [[Bug: AutomaticSummary can overwrite existing pages]] revised by tamc ([[changes => /revision/Bug: AutomaticSummary can overwrite existing pages?time=1127801213]])
123
+ * 02:06 - [[Fixed Bug: AutomaticSummary does not remove pages]] revised by tamc ([[changes => /revision/Fixed Bug: AutomaticSummary does not remove pages?time=1127801175]])
124
+ * 02:05 - [[Bug: AutomaticSummary does not remove pages]] revised by tamc ([[changes => /revision/Bug: AutomaticSummary does not remove pages?time=1127801154]])
125
+ * 02:04 - [[News: Soks 1.0.2 released]] revised by tamc ([[changes => /revision/News: Soks 1.0.2 released?time=1127801053]])
11
126
  * 00:23 - [[Distribution Home Page]] revised by tamc ([[changes => /revision/Distribution Home Page?time=1127795035]])
12
127
  * 00:22 - [[README]] revised by tamc ([[changes => /revision/README?time=1127794944]])
13
128
 
14
- h2. Last Sunday
129
+ h2. 25 Sep
15
130
 
16
131
  * 16:01 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1127678488]])
17
132
 
18
- h2. Last Friday
133
+ h2. 23 Sep
19
134
 
20
135
  * 09:37 - [[View-2]] revised by cristi ([[changes => /revision/View-2?time=1127482640]])
21
136
 
@@ -93,7 +208,7 @@ h2. 23 Aug
93
208
  * 18:00 - [[[Soks] Switch from CVS to Darcs]] revised by Tom Counsell ([[changes => /revision/[Soks] Switch from CVS to Darcs?time=1124834437]])
94
209
  * 18:00 - [[Changes to Soks-development]] revised by DarcsWatcher ([[changes => /revision/Changes to Soks-development?time=1124834431]])
95
210
  * 17:02 - [[Planned Features]] revised by tamc2 ([[changes => /revision/Planned Features?time=1124830923]])
96
- * 14:46 - [[home page]] revised by Joseph Huang ([[changes => /revision/home page?time=1124822779]])
211
+ * 14:46 - [[Home Page]] revised by Joseph Huang ([[changes => /revision/Home Page?time=1124822779]])
97
212
  * 06:13 - [[DarcsWatcher]] revised by tamc2 ([[changes => /revision/DarcsWatcher?time=1124792021]])
98
213
  * 06:08 - [[How to enable a blog]] revised by tamc2 ([[changes => /revision/How to enable a blog?time=1124791719]])
99
214
  * 06:07 - [[WatchPage]] revised by tamc2 ([[changes => /revision/WatchPage?time=1124791661]])
@@ -107,12 +222,12 @@ h2. 23 Aug
107
222
 
108
223
  h2. 18 Aug
109
224
 
110
- * 17:37 - [[home page]] revised by tamc2 ([[changes => /revision/home page?time=1124401051]])
225
+ * 17:37 - [[Home Page]] revised by tamc2 ([[changes => /revision/Home Page?time=1124401051]])
111
226
  * 17:30 - [[How to enable a blog]] revised by tamc2 ([[changes => /revision/How to enable a blog?time=1124400618]])
112
227
  * 14:38 - [[List of changes]] revised by tamc2 ([[changes => /revision/List of changes?time=1124390324]])
113
228
  * 11:24 - [[SOKS features]] revised by Joseph Huang ([[changes => /revision/SOKS features?time=1124378672]])
114
- * 11:21 - [[home page]] revised by Joseph Huang ([[changes => /revision/home page?time=1124378502]])
115
- * 11:14 - [[home page]] revised by tamc2 ([[changes => /revision/home page?time=1124378053]])
229
+ * 11:21 - [[Home Page]] revised by Joseph Huang ([[changes => /revision/Home Page?time=1124378502]])
230
+ * 11:14 - [[Home Page]] revised by tamc2 ([[changes => /revision/Home Page?time=1124378053]])
116
231
  * 11:13 - [[Distribution Home Page]] revised by tamc2 ([[changes => /revision/Distribution Home Page?time=1124378036]])
117
232
  * 11:12 - [[How to hack soks]] revised by tamc2 ([[changes => /revision/How to hack soks?time=1124377944]])
118
233
  * 11:11 - [[Soks's Licence]] revised by tamc2 ([[changes => /revision/Soks's Licence?time=1124377871]])
@@ -127,7 +242,7 @@ h2. 17 Aug
127
242
 
128
243
  h2. 16 Aug
129
244
 
130
- * 07:45 - [[home page]] revised by Joseph Huang ([[changes => /revision/home page?time=1124192735]])
245
+ * 07:45 - [[Home Page]] revised by Joseph Huang ([[changes => /revision/Home Page?time=1124192735]])
131
246
  * 05:59 - [[Planned Features]] revised by Bil Kleb ([[changes => /revision/Planned Features?time=1124186356]])
132
247
  * 04:27 - [[Planned Features]] revised by tamc2 ([[changes => /revision/Planned Features?time=1124180868]])
133
248
 
@@ -202,7 +317,7 @@ h2. 27 Jul
202
317
  * 10:39 - [[How to hack soks]] revised by Giulio Piancastelli ([[changes => /revision/How to hack soks?time=1122475152]])
203
318
  * 10:29 - [[Bug: Wrong title in Result Search page]] revised by Giulio Piancastelli ([[changes => /revision/Bug: Wrong title in Result Search page?time=1122474575]])
204
319
  * 10:26 - [[To Do List]] revised by Giulio Piancastelli ([[changes => /revision/To Do List?time=1122474419]])
205
- * 06:02 - [[home page]] revised by tamc2 ([[changes => /revision/home page?time=1122458556]])
320
+ * 06:02 - [[Home Page]] revised by tamc2 ([[changes => /revision/Home Page?time=1122458556]])
206
321
  * 05:52 - [[Latest News]] revised by tamc2 ([[changes => /revision/Latest News?time=1122457965]])
207
322
  * 05:22 - [[Recent changes to this site]] revised by tamc2 ([[changes => /revision/Recent changes to this site?time=1122456133]])
208
323
  * 05:03 - [[This is a test]] revised by tamc2 ([[changes => /revision/This is a test?time=1122455013]])
@@ -229,76 +344,6 @@ h2. 25 Jul
229
344
  * 06:43 - [[How to use the automatic summary classes]] revised by tamc2 ([[changes => /revision/How to use the automatic summary classes?time=1122288204]])
230
345
  * 05:21 - [[To Do List]] revised by tamc2 ([[changes => /revision/To Do List?time=1122283272]])
231
346
 
232
- h2. 24 Jul
233
-
234
- * 14:48 - [[home page]] revised by tamc2 ([[changes => /revision/home page?time=1122230929]])
235
- * 14:20 - [[Distribution Home Page]] revised by tamc2 ([[changes => /revision/Distribution Home Page?time=1122229219]])
236
- * 13:57 - [[News: Version 1-0-0 released]] revised by tamc2 ([[changes => /revision/News: Version 1-0-0 released?time=1122227862]])
237
- * 13:57 - [[How to upgrade soks]] revised by tamc2 ([[changes => /revision/How to upgrade soks?time=1122227823]])
238
- * 13:39 - [[List of changes]] revised by tamc2 ([[changes => /revision/List of changes?time=1122226760]])
239
- * 13:37 - [[News: Next release due, so this site is being edited]] revised by tamc2 ([[changes => /revision/News: Next release due, so this site is being edited?time=1122226630]])
240
- * 13:32 - [[SOKS features]] revised by tamc2 ([[changes => /revision/SOKS features?time=1122226369]])
241
- * 13:27 - [[Bug: Pages that link here may not appear on restart]] revised by tamc2 ([[changes => /revision/Bug: Pages that link here may not appear on restart?time=1122226056]])
242
- * 13:27 - [[vised on 2005 J]] revised by tamc2 ([[changes => /revision/vised on 2005 J?time=1122226041]])
243
- * 13:18 - [[Tag: Include this page in the distribution]] revised by tamc2 ([[changes => /revision/Tag: Include this page in the distribution?time=1122225508]])
244
- * 13:17 - [[Bug: Competing edits]] revised by tamc2 ([[changes => /revision/Bug: Competing edits?time=1122225439]])
245
- * 09:27 - [[Sidebar Page]] revised by tamc2 ([[changes => /revision/Sidebar Page?time=1122211640]])
246
- * 09:09 - [[Recent changes to this site]] revised by tamc2 ([[changes => /revision/Recent changes to this site?time=1122210575]])
247
- * 09:00 - [[[Soks] email addresses imported to wiki]] revised by Bil.Kleb@NASA.gov ([[changes => /revision/[Soks] email addresses imported to wiki?time=1122210004]])
248
- * 09:00 - [[README]] revised by tamc2 ([[changes => /revision/README?time=1122210003]])
249
- * 08:35 - [[Bug: Memory leak]] revised by tamc2 ([[changes => /revision/Bug: Memory leak?time=1122208534]])
250
- * 08:35 - [[Bug: Email adresses in page titles cause incorrect links]] revised by tamc2 ([[changes => /revision/Bug: Email adresses in page titles cause incorrect links?time=1122208520]])
251
- * 08:35 - [[Bug: E-mail addresses with hyphens not recognised]] revised by tamc2 ([[changes => /revision/Bug: E-mail addresses with hyphens not recognised?time=1122208507]])
252
- * 08:33 - [[Bug: Textile mishandles paragraphs]] revised by tamc2 ([[changes => /revision/Bug: Textile mishandles paragraphs?time=1122208436]])
253
- * 08:33 - [[Bug: Unanticipated Rollbacks]] revised by tamc2 ([[changes => /revision/Bug: Unanticipated Rollbacks?time=1122208398]])
254
- * 08:32 - [[Bug: notextile does not prevent page inserts]] revised by tamc2 ([[changes => /revision/Bug: notextile does not prevent page inserts?time=1122208370]])
255
- * 08:32 - [[Bug: GEM limits title lengths]] revised by tamc2 ([[changes => /revision/Bug: GEM limits title lengths?time=1122208356]])
256
- * 08:31 - [[Bug: Does not make use of if-modified-since request headers]] revised by tamc2 ([[changes => /revision/Bug: Does not make use of if-modified-since request headers?time=1122208295]])
257
- * 08:31 - [[How to import data]] revised by tamc2 ([[changes => /revision/How to import data?time=1122208269]])
258
- * 08:30 - [[How to import data to this wiki]] revised by tamc2 ([[changes => /revision/How to import data to this wiki?time=1122208228]])
259
- * 08:28 - [[How to password protect your wiki]] revised by tamc2 ([[changes => /revision/How to password protect your wiki?time=1122208126]])
260
- * 08:23 - [[How to get the latest Soks from cvs]] revised by tamc2 ([[changes => /revision/How to get the latest Soks from cvs?time=1122207828]])
261
- * 08:21 - [[Bug: Type a title here]] revised by tamc2 ([[changes => /revision/Bug: Type a title here?time=1122207715]])
262
- * 08:20 - [[How to report a bug]] revised by tamc2 ([[changes => /revision/How to report a bug?time=1122207649]])
263
- * 08:19 - [[How to use this wiki]] revised by tamc2 ([[changes => /revision/How to use this wiki?time=1122207587]])
264
- * 08:19 - [[How to use the keyboard shortcuts]] revised by tamc2 ([[changes => /revision/How to use the keyboard shortcuts?time=1122207567]])
265
- * 08:19 - [[How to install Soks]] revised by tamc2 ([[changes => /revision/How to install Soks?time=1122207554]])
266
- * 08:18 - [[How to hack soks]] revised by tamc2 ([[changes => /revision/How to hack soks?time=1122207534]])
267
- * 08:18 - [[How to export a site from this wiki]] revised by tamc2 ([[changes => /revision/How to export a site from this wiki?time=1122207511]])
268
- * 08:17 - [[How to change the way this wiki looks]] revised by tamc2 ([[changes => /revision/How to change the way this wiki looks?time=1122207465]])
269
- * 08:17 - [[How to administrate this wiki]] revised by tamc2 ([[changes => /revision/How to administrate this wiki?time=1122207449]])
270
- * 08:16 - [[Planned Features]] revised by tamc2 ([[changes => /revision/Planned Features?time=1122207405]])
271
- * 08:16 - [[RSS feed]] revised by tamc2 ([[changes => /revision/RSS feed?time=1122207373]])
272
- * 08:15 - [[Per Wiki Templates]] revised by tamc2 ([[changes => /revision/Per Wiki Templates?time=1122207327]])
273
- * 08:15 - [[How to import a site from instiki]] revised by tamc2 ([[changes => /revision/How to import a site from instiki?time=1122207308]])
274
- * 08:14 - [[Api for classes to modify the wiki]] revised by tamc2 ([[changes => /revision/Api for classes to modify the wiki?time=1122207289]])
275
- * 08:08 - [[Pages to include in the distribution]] revised by tamc2 ([[changes => /revision/Pages to include in the distribution?time=1122206904]])
276
- * 07:15 - [[Automatic Summaries]] revised by tamc2 ([[changes => /revision/Automatic Summaries?time=1122203759]])
277
- * 07:15 - [[Author]] revised by tamc2 ([[changes => /revision/Author?time=1122203732]])
278
- * 07:15 - [[Soks Licence]] revised by tamc2 ([[changes => /revision/Soks Licence?time=1122203704]])
279
- * 07:13 - [[Automatic linking between pages]] revised by tamc2 ([[changes => /revision/Automatic linking between pages?time=1122203593]])
280
- * 06:40 - [[Latest News]] revised by tamc2 ([[changes => /revision/Latest News?time=1122201651]])
281
- * 05:38 - [[Not a Soks Bug: Sok CVS tar file has "implausibly old time stamp"]] revised by tamc2 ([[changes => /revision/Not a Soks Bug: Sok CVS tar file has "implausibly old time stamp"?time=1122197934]])
282
- * 05:38 - [[Bug: Sok CVS tar file has "implausibly old time stamp"]] revised by tamc2 ([[changes => /revision/Bug: Sok CVS tar file has "implausibly old time stamp"?time=1122197934]])
283
- * 05:17 - [[To Do List]] revised by tamc2 ([[changes => /revision/To Do List?time=1122196657]])
284
-
285
- h2. 23 Jul
286
-
287
- * 18:41 - [[Bug: Memory leak]] revised by tamc2 ([[changes => /revision/Bug: Memory leak?time=1122158464]])
288
- * 17:25 - [[Fixed Bug: RSS feed does not validate]] revised by tamc2 ([[changes => /revision/Fixed Bug: RSS feed does not validate?time=1122153907]])
289
- * 17:23 - [[Bug: RSS feed does not validate]] revised by tamc2 ([[changes => /revision/Bug: RSS feed does not validate?time=1122153827]])
290
- * 17:19 - [[Fixed bug: calendar does not appear]] revised by tamc2 ([[changes => /revision/Fixed bug: calendar does not appear?time=1122153555]])
291
- * 17:19 - [[bug: calendar does not appear]] revised by tamc2 ([[changes => /revision/bug: calendar does not appear?time=1122153551]])
292
- * 17:16 - [[Fixed bug: viewing revisions requires authentification]] revised by tamc2 ([[changes => /revision/Fixed bug: viewing revisions requires authentification?time=1122153413]])
293
- * 17:16 - [[Fixed Bug: automatic linking does not work with trailing punctuation]] revised by tamc2 ([[changes => /revision/Fixed Bug: automatic linking does not work with trailing punctuation?time=1122153411]])
294
- * 17:16 - [[bug: viewing revisions requires authentification]] revised by tamc2 ([[changes => /revision/bug: viewing revisions requires authentification?time=1122153408]])
295
- * 17:14 - [[List of changes]] revised by tamc2 ([[changes => /revision/List of changes?time=1122153293]])
296
- * 17:14 - [[Bug: automatic linking does not work with trailing punctuation]] revised by tamc2 ([[changes => /revision/Bug: automatic linking does not work with trailing punctuation?time=1122153292]])
297
- * 17:11 - [[Fixed Bug: pages names with single quotes]] revised by tamc2 ([[changes => /revision/Fixed Bug: pages names with single quotes?time=1122153070]])
298
- * 17:10 - [[Bug: pages names with single quotes]] revised by tamc2 ([[changes => /revision/Bug: pages names with single quotes?time=1122153022]])
299
- * 12:13 - [[Fixed Bug: Recent changes today can be yesterday]] revised by tamc2 ([[changes => /revision/Fixed Bug: Recent changes today can be yesterday?time=1122135201]])
300
- * 12:13 - [[Bug: Recent changes today can be yesterday]] revised by tamc2 ([[changes => /revision/Bug: Recent changes today can be yesterday?time=1122135200]])
301
-
302
347
 
303
348
  </div>
304
349
 
@@ -1,6 +1,6 @@
1
- Home Page
2
- Site Index
3
- Known Bugs
1
+ [[ Home Page ]]
2
+ [[ Site Index ]]
3
+ [[ Known Bugs ]]
4
4
  [[ Recent Changes => recent changes to this site ]]
5
5
 
6
6
  <!-- Tag: Include this page in the distribution -->
@@ -5,6 +5,7 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
5
5
  <automaticsummary>
6
6
 
7
7
  * [[ 2005 Apr ]]
8
+ * [[ 2005 Mar 19 ]]
8
9
  * [[ [ANN] Defaultable 0.0.3 ]]
9
10
  * [[ [ANN] Soks - Yet Another Wiki ]]
10
11
  * [[ [Fwd: NASA Half-summer of Code] ]]
@@ -14,6 +15,7 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
14
15
  * [[ [Soks] [Fwd: *cloth and ToC] ]]
15
16
  * [[ [Soks] [Fwd: Another neat Soks Wiki thing] ]]
16
17
  * [[ [Soks] [Fwd: Re: [ redcloth-Bugs-1640 ] email addresses with a ]]
18
+ * [[ [Soks] [Fwd: Re: [Rails] WriteBoard - Compare Revisions - How'd they do that?] ]]
17
19
  * [[ [Soks] [Fwd: Re: Soks rocks (but now need "deep" search capability)] ]]
18
20
  * [[ [Soks] Annotations ]]
19
21
  * [[ [Soks] automatic summaries and page expiration dates ]]
@@ -29,12 +31,15 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
29
31
  * [[ [Soks] email addresses imported to wiki ]]
30
32
  * [[ [Soks] Enabling blogs? ]]
31
33
  * [[ [Soks] feature descriptions ]]
34
+ * [[ [Soks] File upload bug ]]
32
35
  * [[ [Soks] home page counter ]]
36
+ * [[ [Soks] import script gone wild? ]]
33
37
  * [[ [Soks] Linking to attached files ]]
34
38
  * [[ [Soks] non-greedy regexps in automatic summary ]]
35
39
  * [[ [Soks] page counters, etc. ]]
36
40
  * [[ [Soks] page templates/categories ]]
37
41
  * [[ [Soks] Parentheses ]]
42
+ * [[ [Soks] Pathname behavior ]]
38
43
  * [[ [Soks] Popular pages default refresh rate ]]
39
44
  * [[ [Soks] Q: how to I change the default "home page" for WEBrick? ]]
40
45
  * [[ [Soks] Re: [Fwd: Soks rocks] ]]
@@ -47,6 +52,7 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
47
52
  * [[ [Soks] soks site down ]]
48
53
  * [[ [Soks] Soks speed ]]
49
54
  * [[ [Soks] Soks-0.0.5: RecentChanges ignoring 'changes' argument? ]]
55
+ * [[ [Soks] soks-create-wiki.rb upgrade ]]
50
56
  * [[ [Soks] Some counter thoughts ]]
51
57
  * [[ [Soks] Sub wikis ]]
52
58
  * [[ [Soks] Switch from CVS to Darcs ]]
@@ -60,6 +66,7 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
60
66
  * [[ A page with an umlaut � in its title ]]
61
67
  * [[ Picture of a pair of soks ]]
62
68
  * [[ AHoward ]]
69
+ * [[ All categories ]]
63
70
  * [[ All News ]]
64
71
  * [[ Api for classes to modify the wiki ]]
65
72
  * [[ Author ]]
@@ -72,16 +79,16 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
72
79
  * [[ AW: soks vs. instiki ]]
73
80
  * [[ Picture of bad_buttons_bad ]]
74
81
  * [[ Picture of bad_buttons_better ]]
82
+ * [[ Picture of Bil ]]
75
83
  * [[ Bil ]]
76
84
  * [[ Bil Kleb ]]
77
85
  * [[ Bill Wood ]]
78
- * [[ Bug: AutomaticSummary can overwrite existing pages ]]
79
- * [[ Bug: AutomaticSummary does not remove pages ]]
80
86
  * [[ Bug: Competing edits ]]
81
87
  * [[ Bug: Does not make use of if-modified-since request headers ]]
82
88
  * [[ Bug: edit pages display the title of pages with inverted commas incorrectly ]]
83
89
  * [[ Bug: Email adresses in page titles cause incorrect links ]]
84
90
  * [[ Bug: ERROR stack level too deep: day ]]
91
+ * [[ Bug: File Uploads broken for Internet Explorer 6.0 ]]
85
92
  * [[ Bug: GEM limits title lengths ]]
86
93
  * [[ Bug: Memory leak ]]
87
94
  * [[ Bug: notextile does not prevent page inserts ]]
@@ -104,7 +111,9 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
104
111
  * [[ Fixed Bug: automatic linking does not work with trailing punctuation ]]
105
112
  * [[ Fixed Bug: AutomaticPageMover still apears in RecentChanges ]]
106
113
  * [[ Fixed Bug: AutomaticRecentChanges ignores changes parameter ]]
114
+ * [[ Fixed Bug: AutomaticSummary can overwrite existing pages ]]
107
115
  * [[ Fixed Bug: AutomaticSummary does not reflect changes to summarised pages ]]
116
+ * [[ Fixed Bug: AutomaticSummary does not remove pages ]]
108
117
  * [[ Fixed bug: calendar does not appear ]]
109
118
  * [[ Fixed Bug: Cannot change capitalization of a page title ]]
110
119
  * [[ Fixed Bug: Certain text crashes yaml revision loading ]]
@@ -142,9 +151,8 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
142
151
  * [[ Fixed Bug: Uploads are not password protected ]]
143
152
  * [[ Fixed bug: viewing revisions requires authentification ]]
144
153
  * [[ Fixed Bug: Wrong title in Result Search page ]]
145
- * [[ GoDaddy.com Order Confirmation ]]
146
154
  * [[ Picture of hh.jpg ]]
147
- * [[ home page ]]
155
+ * [[ Home Page ]]
148
156
  * [[ How to add movies, svg, flash and other embedded objects ]]
149
157
  * [[ How to administrate this wiki ]]
150
158
  * [[ How to change the way this wiki looks ]]
@@ -173,6 +181,7 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
173
181
  * [[ New page templates or categories code ]]
174
182
  * [[ New Recent Changes class ]]
175
183
  * [[ News: Next release due, so this site is being edited ]]
184
+ * [[ News: Soks 1.0.2 released ]]
176
185
  * [[ News: Switch from CVS to Darcs ]]
177
186
  * [[ News: Version 0.0.6 Released ]]
178
187
  * [[ News: Version 0.0.7 Released ]]
@@ -180,6 +189,7 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
180
189
  * [[ News: Version 1-0-1 released ]]
181
190
  * [[ News: Version numbering system change ]]
182
191
  * [[ Not a Soks Bug: Sok CVS tar file has "implausibly old time stamp" ]]
192
+ * [[ Page test ]]
183
193
  * [[ Pages to include in the distribution ]]
184
194
  * [[ paragraphs and explicit linebreaks ]]
185
195
  * [[ Per Wiki Templates ]]
@@ -219,10 +229,9 @@ p{font-size: x-small;}. Site Index was created automatically from pages whose ti
219
229
  * [[ Thinking about meta-data ]]
220
230
  * [[ This is a test ]]
221
231
  * [[ To Do List ]]
232
+ * [[ Picture of Tom Counsell ]]
222
233
  * [[ Try Ruwiki, too (Re: [ANN] Soks - Yet Another Wiki) ]]
223
- * [[ Type a title here ]]
224
234
  * [[ Ugly Page URLs in Soks ]]
225
- * [[ View-2 ]]
226
235
  * [[ WatchPage ]]
227
236
  * [[ What's the best way to write a Textile-to-PDF::Writer converter? ]]
228
237
  * [[ Why "pre" AND "code" tags in Textile Markup? ]]
@@ -8,16 +8,15 @@ $LOG.level = Logger::DEBUG
8
8
  $LOG.datetime_format = "%Y-%m-%d %H:%M:%S"
9
9
 
10
10
  #Add the required libraries to the search path
11
- begin
12
- require 'rubygems'
13
- require_gem 'Soks', '~> <%= settings[:version] %>'
14
- $LOG.info 'Loaded Soks from gem'
15
- rescue LoadError
16
- $LOG.info "Soks Gem version <%= settings[:version] %> could not be found"
17
- $:.push( "<%= settings[:soks_libraries].join('","') %>" )
18
- require 'soks'
19
- $LOG.info 'Loaded Soks libraries from <%= settings[:soks_libraries].join('","') %>'
20
- end
11
+ <% if $IS_GEM %>
12
+ require 'rubygems'
13
+ require_gem 'Soks', '~> <%= settings[:version] %>'
14
+ $LOG.info 'Loaded Soks from gem'
15
+ <% else %>
16
+ $:.push( "<%= settings[:soks_libraries].join('","') %>" )
17
+ require 'soks'
18
+ $LOG.info 'Loaded Soks libraries from <%= settings[:soks_libraries].first.to_s %>'
19
+ <% end %>
21
20
 
22
21
  $LOG.info "Running Soks version #{SOKS_VERSION}"
23
22
 
@@ -1 +1 @@
1
- 1.0.2
1
+ 1.0.3
@@ -38,10 +38,10 @@
38
38
  </div>
39
39
 
40
40
  <% if page %>
41
- <% dynamic_links = page.links_to - sidebarpage.links_from - [ sidebarpage ] %>
41
+ <% dynamic_links = page.links_to - page.links_from - sidebarpage.links_from - [ sidebarpage ] %>
42
42
  <% dynamic_links.delete_if { |page| page.name =~ /^Site Index ([a-z]|Other)\./i } %>
43
43
  <% unless dynamic_links.empty? %>
44
- <h2>Pages that link here</h2>
44
+ <h2>See also:</h2>
45
45
  <div class='linklist'>
46
46
  <% dynamic_links.each do |linkedpage| %>
47
47
  <a href='<%= url linkedpage.name %>'><%= linkedpage.name %></a>
@@ -215,6 +215,15 @@ class TestWikiServlet < Test::Unit::TestCase
215
215
  assert_equal( '/Attachment/testfile.txt', page.content )
216
216
  end
217
217
 
218
+ def test_upload_clean_up_names
219
+ filedata = MockFileData.new 'C:/Documents and Settings/AB/Desktop/bil_kleb1.jpg'
220
+ @servlet.service( re = MockRequest[ :path => '/upload/upload test' , :user => 'uploader', :query => { 'file' => filedata, 'titleprefix' => 'upload ', 'newtitle' => 'test'} ], rp = MockResponse.new )
221
+ assert_equal( 'http://testsite.com/view/UploadTest', rp[:redirect_destination] )
222
+ page = @wiki.page('upload test')
223
+ assert_equal( 'uploader', page.author )
224
+ assert_equal( '/Attachment/bil_kleb1.jpg', page.content )
225
+ end
226
+
218
227
  def test_move_upload
219
228
  test_upload
220
229
  filedata = MockFileData.new
@@ -81,6 +81,12 @@ class FileUniqueFilenameTest < Test::Unit::TestCase
81
81
  assert_equal( 'ok.txt', File.unique_filename( folder, 'o k.txt' ) )
82
82
  end
83
83
 
84
+ def test_strip_everything_but_the_name
85
+ assert_equal( 'tamcpicture.jpg', File.unique_filename( folder,'/home/tamc/good\ stuff/tamc\ picture.jpg') )
86
+ assert_equal( 'bil_kleb1.jpg', File.unique_filename( folder,'C:\Documents and Settings\AB\Desktop\bil_kleb1.jpg') )
87
+ assert_equal( 'bil_kleb1.jpg', File.unique_filename( folder,'C:\Documents and Settings\AB\Desktop\bil_*$kleb1.jpg') )
88
+ end
89
+
84
90
  def test_collision
85
91
  assert_equal( 'ok.txt', File.unique_filename( folder, 'ok.txt' ) )
86
92
  create_file 'ok.txt', ''
metadata CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.8.11
3
3
  specification_version: 1
4
4
  name: Soks
5
5
  version: !ruby/object:Gem::Version
6
- version: 1.0.2
7
- date: 2005-09-27 00:00:00 +01:00
6
+ version: 1.0.3
7
+ date: 2005-10-18 00:00:00 +01:00
8
8
  summary: Yet another wiki.
9
9
  require_paths:
10
10
  - lib