Skip to content

Instantly share code, notes, and snippets.

View ogrigas's full-sized avatar

Osvaldas Grigas ogrigas

  • Vilnius, Lithuania
View GitHub Profile

Keybase proof

I hereby claim:

  • I am ogrigas on github.
  • I am ogrigas (https://keybase.io/ogrigas) on keybase.
  • I have a public key ASA3YuNNH7PJL8BzNWXa53H2wUMXFrz-2pS-7HfLj_HUlgo

To claim this, I am signing this object:

testCompile "junit:junit:4.12"
testCompile "org.hamcrest:hamcrest-library:1.3"
testCompile "org.mockito:mockito-core:2.7.19"
@ogrigas
ogrigas / website-monitor-example.py
Created March 7, 2016 09:16
Example Python script that pings a website and sends email alert in case it's unreachable
from urllib2 import urlopen
def send_alert():
from smtplib import SMTP
from email.mime.text import MIMEText
msg = MIMEText('nuf said')
msg['Subject'] = 'inventi.lt is unreachable'
msg['From'] = '[email protected]'
@Entity
@Table(name = "orders", schema = "com"})
public class Order implements Serializable {
@Id
@GeneratedValue(strategy = SEQUENCE, generator = "order_seq")
@Column(name = "ID", unique = true, nullable = false)
private Integer id;
@Column(name = "NUMBER", nullable = false, length = 8)