curl -u Jenkins:Jenkins -H "Content-Type: application/json" -X POST http://localhost:7990/rest/build-status/1.0/commits/$GIT_COMMIT -d '{"state":"INPROGRESS","key": "'$BUILD_TAG'","name": "Jenkins-'$BUILD_DISPLAY_NAME'", "url": "'$BUILD_URL'/consoleText","description": "Changes by '$GIT_COMMITTER_EMAIL'"}'
#!/bin/sh
cd ${WORKSPACE}
SUCCESS=true
gem install bundler --no-rdoc --no-ri || SUCCESS=false
bundle install || SUCCESS=false
bundle exec rake db:create || SUCCESS=false
This file contains 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
Coverage Badges |
This file contains 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
coś takiego: | |
# frozen_string_literal: true | |
class Shop::Settings | |
ALL_TERMINAL_LOCKERS_OPEN_ENABLED = "ALL_TERMINAL_LOCKERS_OPEN_ENABLED" | |
API_GATEWAY_NAME = "api_gateway_name" | |
ASSISTANCE_ENABLED = "ASSISTANCE_ENABLED" | |
CHECK_IN_FREE_LOCKER_ENABLED = "CHECK_IN_FREE_LOCKER_ENABLED" | |
CHECK_IN_MAILER_ENABLED = "CHECK_IN_MAILER_ENABLED" | |
CUSTOMER_CAR_SERVICE_SMS_ENABLED = "CUSTOMER_CAR_SERVICE_SMS_ENABLED" |
This file contains 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
$cropper_width = $data['additional_product_information']['cropper_width']; | |
$cropper_height = $data['additional_product_information']['cropper_height']; | |
$cropper_x = $data['additional_product_information']['cropper_x']; | |
$cropper_y = $data['additional_product_information']['cropper_y']; | |
$filename = $data['additional_product_information']['thumbnail_url']; | |
header('Content-type: image/jpg'); | |
header('Content-Disposition: attachment; filename='.$src); | |
$image = imagecreatefromjpeg($filename); | |
$crop = imagecreatetruecolor($cropper_width,$cropper_height); | |
imagecopy ( $crop, $image, 0, 0, $cropper_x, $cropper_y, $cropper_width, $cropper_height ); |
This file contains 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 index | |
puts '!!!!!!' | |
if current_user.sportsman? | |
@time_range = Date.today.at_beginning_of_month-6.days..Date.today.at_end_of_month+6.days | |
@trainings = Training.includes(:trainings_executions).where(start_date: @time_range, trainings_executions: {sportsman_id: current_user.id}).order(:start_time) | |
else | |
date = params[:start_date] ? params[:start_date].to_date : Date.today | |
@time_range = date.at_beginning_of_week..date.at_end_of_week | |
@training = Training.new | |
if current_user.coach? |
This file contains 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
" Pathogen ******************************************************************* | |
call pathogen#incubate() | |
call pathogen#helptags() | |
" General ******************************************************************** | |
set nocompatible | |
set encoding=utf-8 | |
set fileencodings=utf-8,latin2 | |
" Autowrite current buffer on switch |
This file contains 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
[user] | |
email = mylosz@yahoo.pl | |
name = Miłosz Osiński | |
[alias] | |
br = branch | |
co = checkout | |
ci = commit | |
df = diff | |
lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit |
This file contains 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
# ~/.bashrc: executed by bash(1) for non-login shells. | |
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) | |
# for examples | |
# If not running interactively, don't do anything | |
case $- in | |
*i*) ;; | |
*) return;; | |
esac |
This file contains 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
======= Prolbem ================================================================================================================= | |
I have installed : ruby-2.0.0,postgres-9.2 , now in rails app when I execute: | |
rake db:create , command I get: | |
PG::InvalidParameterValue: ERROR: new encoding (UTF8) is incompatible with the encoding of the template database (SQL_ASCII) | |
HINT: Use the same encoding as in the template database, or use template0 as template. | |
: CREATE DATABASE "my_db_name" ENCODING = 'unicode'....... | |
================================================================================================================================= |
This file contains 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() { | |
$('input[type=number]').keydown(function (e) { | |
var key = e.which || e.keyCode; | |
if (!e.shiftKey && !e.altKey && !e.ctrlKey && | |
// numbers | |
key >= 48 && key <= 57 || | |
// Numeric keypad | |
key >= 96 && key <= 105 || | |
// comma, period and minus, . on keypad |
NewerOlder