This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| hist = log --pretty=format:\"%C(yellow)%h %C(cyan)%ad %C(white)| %s%C(green bold)%d %Creset%C(magenta)[%an]\" --graph --date=rfc |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Author: Nicolas Meylan | |
| # Date: 22.10.14 | |
| # Encoding: UTF-8 | |
| # File: qt_app.rb | |
| require 'Qt' | |
| class QtApp < Qt::Widget | |
| # Constants | |
| MINERAL_COLORS = {A: '#006BFF', B: '#00ff45', V: '#e4e4e4', AGENT: '#A1499E'} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Sub AddProgressBar() | |
| On Error Resume Next | |
| With ActivePresentation | |
| sHeight = .PageSetup.SlideHeight - 60 | |
| sImage1Path = ActivePresentation.Path + "\Image1.png" | |
| sImage2Path = ActivePresentation.Path + "\Image2.png" | |
| sImage3Path = ActivePresentation.Path + "\Image3.png" | |
| n = 0 | |
| j = 0 | |
| For i = 1 To .Slides.Count |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| brew install qt | |
| # Install ruby version with following options. | |
| CC=clang CONFIGURE_OPTS="--with-gcc=clang --enable-shared" rvm install 'version' | |
| gem install qtbindings | |
| # It's work |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| JRUBY_OPTS='-J-XstartOnFirstThread' | |
| JRUBY_OPTS=' -J-XstartOnFirstThread' ruby app.rb |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function highlight_search() { | |
| var search_box = $('#highlight_search'); | |
| var input = search_box.find('input'); | |
| search_box.keydown(function (e) { | |
| highlight_result(e, input) | |
| }); | |
| $('html').keydown(function (e) { | |
| var ctrl = e.ctrlKey, cmd = e.metaKey, f3_key = 114, f_key = 70; | |
| if (e.keyCode === f3_key || ((ctrl || cmd) && e.keyCode === f_key)) { | |
| e.preventDefault(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.lang.annotation.Annotation; | |
| import javax.servlet.http.HttpServletRequest; | |
| import javax.servlet.http.HttpServletResponse; | |
| import org.springframework.stereotype.Controller; | |
| import org.springframework.web.method.HandlerMethod; | |
| import org.springframework.web.servlet.HandlerInterceptor; | |
| import org.springframework.web.servlet.ModelAndView; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| String.prototype.endsWith = function(suffix) { | |
| return this.indexOf(suffix, this.length - suffix.length) !== -1; | |
| }; | |
| //JSON | |
| $.fn.serializeJSON = function () { | |
| var json = {}; | |
| jQuery.map($(this).serializeArray(), function (n, i) { | |
| if(n['name'].endsWith('[]')){ | |
| if(json[n['name']] === undefined) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def js_redirect_to(path) | |
| render js: %(window.location.href='#{path}') and return | |
| end |
NewerOlder