Go Back   Smogon Community > Contributions & Corrections > Projects
Register FAQ Social Groups Calendar Search Today's Posts Mark Forums Read

Reply
Categories: HTML, Programming, Other
 
Thread Tools
Old Jun 8th, 2010, 11:55:58 PM   #1
Sarenji
leaf-faced
is a Programmeris a Battle Server Admin Alumnusis a Forum Moderator Alumnusis a Researcher Alumnusis a Contributor Alumnus
 
Sarenji's Avatar
 
Join Date: May 2005
Posts: 362
Tristram
Default Peer editors: How to get lazier

What annoyed me greatly when peer editing analyses or articles was the time it took. I hated how I had to write out little dumb BBCode when fixing small stuff. I don't care about writing little dumb BBCode, and I'm sure you don't either.

So I found a diff script by Google and wrote a wrapper around it to turn the diff tool's output into BBCode. In English: This marks every change you made in a peer edit, for you. ♥

http://shaym.in/apps/diff/

How to use:
  • The original analysis/article goes in the Original textbox. Your edited version goes in the New textbox.
  • Press "Diff!"
  • Copy the BBCode. Post it.
  • Cry tears of happiness for lazy programmers.
__________________

Last edited by Rising_Dusk; Feb 16th, 2011 at 10:20:38 PM. Reason: Prefix
Sarenji is offline   Reply With Quote
Old Jun 9th, 2010, 12:19:44 AM   #2
Ray Jay
Clearly cannot choose the wine in front of you
is a Contributor to Smogon Mediais a Forum Moderator Alumnusis a Tiering Contributor Alumnusis a Contributor Alumnus
 
Ray Jay's Avatar
 
Join Date: May 2010
Posts: 1,508
Default

Works great from what I can tell, and wow, what a pun in that website name.
__________________
Don't count the days, make the days count.
Katakiri: How did you even get into this university?
Ray Jay is offline   Reply With Quote
Old Jun 14th, 2010, 4:50:37 PM   #3
Snorlaxe
#bossniggaprobs
is a Contributor to Smogon
 
Snorlaxe's Avatar
 
Join Date: Jun 2009
Posts: 2,232
Default

Eh, I'll still probably edit traditionally, but this still looks quite cool, thanks! :)
Snorlaxe is offline   Reply With Quote
Old Jul 25th, 2010, 6:39:57 PM   #4
Zystral
Time for a true display of skill.
is a Contributor to Smogon Mediais a Contributor to Smogon
 
Zystral's Avatar
 
Join Date: Apr 2009
Posts: 1,392
You belong in a museum!
Default

whistle and myself, along with one or two other users have had a few problems with this thingymajig, so I'll say now
it doesn't always work in firefox, and sometimes doesn't work in chrome
you need to click "Diff!" and hold the button for a while. if that doesn't work try repasting one of the analyses.
It should work with patience and perseverence.
__________________
GP Team - just ask. | last.fm | redditor | steam | #C&C, #mtg, #TCG
oh look a userbar
Zystral is offline   Reply With Quote
Old Jul 26th, 2010, 9:07:27 PM   #5
whistle
is a Contributor to Smogonis a Forum Moderator Alumnusis a Smogon IRC SOp Alumnusis a Smogon Media Contributor Alumnusis a past Smogon Premier League champion
 
whistle's Avatar
 
Join Date: Jan 2009
Posts: 1,610
Location: Chicago
Default

i love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenjii love sarenji

this makes checking stuff ridiculously easy. i even had word macros for bolding + coloring selected text and just formatting the check would take ages even with those shortcuts. excellent app...

about the "doesn't work sometime" thing... zystral swears that you can hold it down but either my firefox is worse than his or i just have a lot less patience so it still doesn't work. but i tried it with chrome and it worked. so if you're a primary firefox user and his method doesn't work you could try to see if it works in chrome (or ie i guess or opera or whatever)
__________________
<&Gouki> whistles sig is the best thing on smogon (slightly updated 3/13/13)
whistle is offline   Reply With Quote
Old Nov 28th, 2012, 1:21:19 AM   #6
sandshrewz
穿山鼠
is a member of the Smogon Site Staffis an Artistis a Forum Moderatoris a Contributor to Smogon Mediais a Contributor to Smogonis a Battle Server Moderator
 
sandshrewz's Avatar
 
Moderator
Join Date: Oct 2010
Posts: 1,513
ASIA
Default

Hello~ Bumping this with permission from Sarenji~ I went ahead and made some changes with help from Google to the diff app. I'm currently putting it on the public folder of my dropbox. It can be accessed here:

http://dl.dropbox.com/u/72762463/diffnew.html

Okay let me take a minute to explain the changes. I've changed it to an Efficiency Cleanup instead of a Semantic Cleanup that was used. ie it should screw up less than Semantic Cleanup. You can try the difference between Efficiency and Semantic Cleanup here. I also added a changable Edit Cost and set it to 3 as a default which I found was the ideal edit cost. Feel free to change it though. Anyway what edit cost means is "Increase computational efficiency by factoring out short commonalities which are not worth the overhead. The larger the edit cost, the more agressive the cleanup." tyvm Google!! LOL.

I also added the Timeout option which you should pay attention to. It just means how long is taken to diff the thing in seconds. 1sec is the default. You can set it to 0 if whatever you're diffing is very long and 0 Timeout means that unlimited time can be taken to diff it. Warning: During the Timeout, your browser might freeze temporarily till the diffing is complete. I'd suggest using Chrome to diff something if it's super long and you're using 0 Timeout. As a guage or something, I used about 30s for Timeout for this. Can't remember it exactly. Maybe it was more :O

Anyway the most noticeable change is that I've added color options!!! Blue and Red are the default colors. I can add more options if anyone finds a need for it~! Feel free to suggest more colors. :)

Anyway as for future plans, I'm going to make the diff app look nicer / style it up. If possible, I'd like to optimize the diffing process ie diff it part by part which might be faster for longer diffs. But my JavaScript knowledge is pretty limited now idk if I can do that >.> Still thinking of a way to escape and allow comments into the diff though! :O!!

Do post feedbacks/suggestions here or if there's any bug to it (I don't think so??) tl;dr just remember that your browser might freeze for a while if you increase timeout or set it to 0!! Have fun GPing! I hope this is a greater incentive to GP too, haha. :P
__________________
Member of the GP Team- VM for a check / stamp!

Last edited by sandshrewz; Nov 28th, 2012 at 1:33:27 AM.
sandshrewz is offline   Reply With Quote
Reply Smogon Community > Contributions & Corrections > Projects

« Previous Thread | Next Thread »
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT -4. The time now is 12:07:33 AM.