From a12d50981b3ee682a62a2f5c8266cc7447031d27 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sat, 10 Aug 2013 15:05:44 +0200 Subject: [PATCH 1/6] Shorter dice format. --- src/Miscellaneous/Dice.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Miscellaneous/Dice.coffee b/src/Miscellaneous/Dice.coffee index 93bdb06cd..7b7a3c386 100644 --- a/src/Miscellaneous/Dice.coffee +++ b/src/Miscellaneous/Dice.coffee @@ -8,4 +8,4 @@ Dice = return if @isClone or not dicestats = @info.email?.match /dice[+\s](\d+)d(\d+)/ # Use the text node directly, as the has two
. roll = $('b', @nodes.comment).firstChild - roll.data = "Rolled #{dicestats[1]}d#{dicestats[2]} and got #{roll.data.slice 7}" + roll.data = "Rolled #{dicestats[1]}d#{dicestats[2]}: #{roll.data.slice 7}" From 4b332e19e0153887b28ff4292461fde68b488ab7 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sat, 10 Aug 2013 15:26:34 +0200 Subject: [PATCH 2/6] Fix #1196, #1222. --- src/Quotelinks/Quotify.coffee | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/Quotelinks/Quotify.coffee b/src/Quotelinks/Quotify.coffee index 1d26c6e79..8f94ee226 100644 --- a/src/Quotelinks/Quotify.coffee +++ b/src/Quotelinks/Quotify.coffee @@ -21,11 +21,15 @@ Quotify = # This won't be necessary once 4chan # stops quotifying inside code tags: # https://github.com/4chan/4chan-JS/issues/77 - $.replace deadlink, [deadlink.childNodes...] + Quotify.fixDeadlink deadlink return quote = deadlink.textContent return unless postID = quote.match(/\d+$/)?[0] + if postID[0] is '0' + # Fix quotelinks that start with a `0`. + Quotify.fixDeadlink deadlink + return boardID = if m = quote.match /^>>>\/([a-z\d]+)/ m[1] else @@ -70,3 +74,6 @@ Quotify = $.replace deadlink, a if $.hasClass a, 'quotelink' @nodes.quotelinks.push a + + fixDeadlink: (deadlink) -> + $.replace deadlink, [deadlink.childNodes...] From 79aa6eb975d5be5f9bcfbd357c40556e3d7f7e75 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sat, 10 Aug 2013 15:34:22 +0200 Subject: [PATCH 3/6] Release 4chan X v3.6.0. --- CHANGELOG.md | 2 ++ package.json | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 353dce5e0..b3b04ffcf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,5 @@ +## 3.6.0 - *2013-08-10* + - **New feature**: `Show Dice Roll` - Shows dice that were entered into the email field on /tg/. - Fix impossibility to create new threads when in dead threads. diff --git a/package.json b/package.json index 33b87d4d9..2f097642f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "4chan-X", - "version": "3.5.7", + "version": "3.6.0", "description": "Cross-browser extension for productive lurking on 4chan.", "meta": { "name": "4chan X", From 1e439167d76d0f8d5fb7631405ee796110107287 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sat, 10 Aug 2013 15:46:48 +0200 Subject: [PATCH 4/6] Shorter QuoteYou code. Not sure why I had written it that way. --- src/Quotelinks/QuoteYou.coffee | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/Quotelinks/QuoteYou.coffee b/src/Quotelinks/QuoteYou.coffee index 3013abd03..11e4763dc 100644 --- a/src/Quotelinks/QuoteYou.coffee +++ b/src/Quotelinks/QuoteYou.coffee @@ -10,11 +10,6 @@ QuoteYou = node: -> # Stop there if it's a clone. return if @isClone - # Stop there if there's no quotes in that post. - return unless (quotes = @quotes).length - {quotelinks} = @nodes - - for quotelink in quotelinks - if QR.db.get Get.postDataFromLink quotelink - $.add quotelink, $.tn QuoteYou.text + for quotelink in quotelinks when QR.db.get Get.postDataFromLink quotelink + $.add quotelink, $.tn QuoteYou.text return From 1d83ccbc12c4ce0e04887ca55aacae042c9432b7 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sat, 10 Aug 2013 15:48:47 +0200 Subject: [PATCH 5/6] .nex files are not necessary anymore. --- Gruntfile.coffee | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/Gruntfile.coffee b/Gruntfile.coffee index 9410f0c6b..535eb2bca 100644 --- a/Gruntfile.coffee +++ b/Gruntfile.coffee @@ -69,15 +69,6 @@ module.exports = (grunt) -> dest: 'builds/crx/' expand: true flatten: true - # for_d19 - # 19 juin 2013 10:32:22 - # We're currently sniffing the type of the file based on file extension. - # We have a different type of content, Themes, which use a pure zip-file with a .zip ending. - # This solution is sub-optimal and will be changed in the future. - # For now, upload an unsigned ZIP-file with the ending .nex or .crx. - nex: - src: 'builds/<%= pkg.name %>.zip' - dest: 'builds/<%= pkg.name %>.nex' coffee: script: src: 'tmp-<%= pkg.type %>/script.coffee' @@ -158,7 +149,7 @@ module.exports = (grunt) -> 'clean:tmpuserscript' ] - grunt.registerTask 'release', ['shell:commit', 'shell:push', 'build-crx', 'compress:crx', 'copy:nex'] + grunt.registerTask 'release', ['shell:commit', 'shell:push', 'build-crx', 'compress:crx'] grunt.registerTask 'patch', ['bump', 'updcl:3', 'release'] grunt.registerTask 'minor', ['bump:minor', 'updcl:2', 'release'] grunt.registerTask 'major', ['bump:major', 'updcl:1', 'release'] From e890680dc4f187d1d010a8606961aa3e9126ae51 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sat, 10 Aug 2013 15:52:24 +0200 Subject: [PATCH 6/6] Fix missing `@nodes.`. --- src/Quotelinks/QuoteYou.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Quotelinks/QuoteYou.coffee b/src/Quotelinks/QuoteYou.coffee index 11e4763dc..acc4d2e64 100644 --- a/src/Quotelinks/QuoteYou.coffee +++ b/src/Quotelinks/QuoteYou.coffee @@ -10,6 +10,6 @@ QuoteYou = node: -> # Stop there if it's a clone. return if @isClone - for quotelink in quotelinks when QR.db.get Get.postDataFromLink quotelink + for quotelink in @nodes.quotelinks when QR.db.get Get.postDataFromLink quotelink $.add quotelink, $.tn QuoteYou.text return