@@ -17,7 +17,6 @@ program
1717 // the do something switches
1818 . option ( '-m, --html' , 'If set, write the minutes to an index.html file' )
1919 . option ( '-e, --email' , 'If set, publish the minutes to the mailing list' )
20- . option ( '-g, --google' , 'If set, publish the minutes to G+' )
2120 . option ( '-i, --index' , 'Build meeting index' )
2221 // the tweak the cli switch
2322 . option ( '-q, --quiet' , 'Don\'t print status information to the console' )
@@ -41,7 +40,7 @@ if(!program.directory) {
4140 process . exit ( 1 ) ;
4241}
4342
44- if ( ! program . html && ! program . email && ! program . google && ! program . index ) {
43+ if ( ! program . html && ! program . email && ! program . index ) {
4544 console . error ( 'Error: Nothing to do...' ) ;
4645 program . outputHelp ( ) ;
4746 process . exit ( 1 ) ;
@@ -83,26 +82,6 @@ if (!('minutes_base_url' in config)) {
8382// Location of date-based minutes folders; MUST end in a forward slash
8483scrawl . minutes_base_url = config . minutes_base_url ;
8584
86- // Mustache template - vars: gDate, formattedItems, content, minutes_base_url
87- const GPLUS_BODY = ( 'gplus' in config && 'body' in config . gplus )
88- ? config . gplus . body
89- : `*Meeting Summary for {{gDate}}*
90-
91- We discussed {{formattedItems}}.
92-
93- {{{content}}}
94-
95- Full transcript and audio logs are available here:
96-
97- {{{minutes_base_url}}}{{gDate}}/
98- ` ;
99-
100- // Mustache template - vars: group, message, gDate, minutes_base_url
101- const TWITTER_BODY = ( 'twitter' in config && 'body' in config . twitter )
102- ? config . twitter . body
103- : `{{group}} discusses {{message}}:
104- {{{minutes_base_url}}}{{gDate}}/` ;
105-
10685/************************* Utility Functions *********************************/
10786function sendEmail ( username , password , hostname , content , callback ) {
10887 var server = email . server . connect ( {
@@ -359,40 +338,6 @@ Full text of the discussion follows for archival purposes.
359338 } else {
360339 callback ( ) ;
361340 }
362- } , function ( callback ) {
363- // format the G+ post for copy-paste
364- if ( program . google ) {
365- if ( ! program . quiet ) {
366- console . log ( 'scrawl: Composing new G+ message.' ) ;
367- }
368-
369- // generate the body of the email
370- var content = scrawl . generateMinutes ( gLogData , 'text' , gDate , haveAudio ) ;
371- content = content . match ( / A g e n d a ( .| \n ) * O r g a n i z e r : / ) [ 0 ] . replace ( 'Organizer:' , '' ) ;
372- var items = content . match ( / T o p i c s ( .| \n ) * ( A c t i o n | R e s o l u t i o n s | .* ) / ) [ 0 ] . match ( / [ 0 - 9 ] { 1 , 2 } \. ( .* ) / g) ;
373- var formattedItems = '' ;
374-
375- // create a brief description of what was discussed
376- for ( var i = 0 ; i < items . length ; i ++ ) {
377- if ( i > 0 && i < items . length - 1 ) {
378- formattedItems += ', ' ;
379- }
380- else if ( i == items . length - 1 ) {
381- formattedItems += ', and ' ;
382- }
383- formattedItems += items [ i ] . replace ( / [ 0 - 9 ] { 1 , 2 } \. / , '' ) . toLowerCase ( ) ;
384- }
385-
386- // format in a way that is readable on G+
387- content = Mustache . render ( GPLUS_BODY , { gDate, formattedItems, content,
388- minutes_base_url : scrawl . minutes_base_url } ) ;
389-
390- console . log ( 'scrawl: You will need to paste this to your G+ stream:\n' ) ;
391- console . log ( content ) ;
392- callback ( ) ;
393- } else {
394- callback ( ) ;
395- }
396341} ] , function ( err ) {
397342 // check to ensure there were no errors
398343 if ( err ) {
0 commit comments