Skip to content

Instantly share code, notes, and snippets.

@antelio
antelio / ZPRAA_ACTIVATION
Last active March 19, 2018 13:25
ZPRAA_ACTIVATION
*&---------------------------------------------------------------------*
*& Report ZPRAA_ACTIVATION
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT zpraa_activation.
@antelio
antelio / limpeza.sql
Created December 14, 2017 18:20
Limpeza MSAF
alter table LIB_PROC_CAB disable constraint FK_LIB_PROC_CAB;
alter table LIB_PROC_LOG disable constraint FK_LIB_PROC_LOG;
alter table LIB_PROC_SAIDA disable constraint FK_LIB_PROC_SAIDA;
alter table LIB_PROC_SAIDA_COMPL disable constraint FK_LIB_PROC_SAIDA_COMPL;
alter table LIB_PROC_REL_PORT63_RPF disable constraint FK_LIB_PROC_REL_PORT63_RPF;
alter table DWT_REL_CONF_PISCOF disable constraint FK_DWT_REL_CONF_PISCOF;
alter table DWT_REL_CONF_PISCOF_MSG disable constraint FK_DWT_REL_CONF_PC_MSG;
alter table ACT_CAD_BEM disable constraint FK_ACT_BEM_PROCESSO;
alter table ACT_CAD_ITEM disable constraint FK_ACT_ITEM_PROCESSO;
alter table ACT_CAD_NAT_OP disable constraint FK_ACT_NATOP_PROCESSO;
@antelio
antelio / Gemfile
Created December 8, 2017 19:22
Gemfile (campus-code)
source 'https://rubygems.org'
gem 'rails', '~> 5.0.0', '>= 5.0.0.1'
gem 'puma', '~> 3.0'
gem 'sass-rails', '~> 5.0'
gem 'uglifier', '>= 1.3.0'
gem 'coffee-rails', '~> 4.2'
gem 'simple_form'
gem 'jquery-rails'
gem 'turbolinks', '~> 5'
gem 'jbuilder', '~> 2.5'
@antelio
antelio / ZFILE_CAT79_2017
Last active May 21, 2018 22:07
ZFILE_CAT79_2017
*&---------------------------------------------------------------------*
*& Report ZFILE_CAT79_2017
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT zfile_cat79_2017.
@antelio
antelio / ZDDIC
Last active March 27, 2018 14:33
RESET SAP*
REPORT zddic.
PARAMETERS:
user TYPE usr01-bname DEFAULT sy-uname,
mandt TYPE mandt DEFAULT sy-mandt.
EXEC SQL.
UPDATE usr02 set BCODE=(select bcode from usr02 where bname= :user and mandt= :mandt)
where bname= :user and mandt='000'
ENDEXEC.
@antelio
antelio / noip2.service
Last active March 19, 2018 13:41 — forked from NathanGiesbrecht/noip2.service
Systemd Service file for no-ip.com dynamic ip updater
# Simple No-ip.com Dynamic DNS Updater
#
# By Nathan Giesbrecht (http://nathangiesbrecht.com)
#
# 1) Install binary as described in no-ip.com's source file (assuming results in /usr/local/bin)
# 2) Run sudo /usr/local/bin/noip2 -C to generate configuration file
# 3) Copy this file noip2.service to /etc/systemd/system/
# 4) Execute `sudo systemctl enable noip2`
# 5) Execute `sudo systemctl start noip2`
#
# initialization file (not found)
@antelio
antelio / btsync.service
Last active March 19, 2018 13:43 — forked from miry/btsync.service
Simple Systemd services for my local server
# create /etc/systemd/system/btsync.service
# systemctl start btsync.service
# systemctl status btsync.service
# systemctl enable btsync.service
[Unit]
Description=BTSync daemon
[Service]
#Type=forking
PIDFile=/run/btsync/btsync.pid
@antelio
antelio / json_util.abap
Created May 31, 2016 02:38 — forked from mydoghasworms/json_util.abap
ABAP Utility class for mapping JSON to ABAP data and vice versa
*----------------------------------------------------------------------*
* CLASS json_util DEFINITION
*----------------------------------------------------------------------*
class json_util definition.
public section.
class-methods:
data_to_json importing data type any
returning value(json) type string,
json_to_data importing json type string
changing data type any.
@antelio
antelio / port_open.rb
Created November 27, 2015 18:24 — forked from ashrithr/port_open.rb
check if port is open on a remote host
#!/usr/bin/env ruby
require 'socket'
require 'timeout'
unless ARGV.length == 2
abort "Usage: ruby #{__FILE__} HOST PORT"
end
def port_open?(ip, port, seconds=1)
# => checks if a port is open or not on a remote host
Timeout::timeout(seconds) do