Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions deploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/bin/bash

cd /var/lib/jenkins

ls -a | grep -w .git

if [ $? -ne 0 ];then
git init
fi

touch .gitignore

echo workspace >> .gitignore

git add *
git commit -m "jenkins_backup on `date`"
git push https://github.com/bhuvaneshwaran29/jenkins_backup.git master

if [ $? -eq 0 ];then
body=`echo -e "Hi,\n Jenkins Backup "`

echo $body | mail -s "jenkins backup success on `date`" - c bhuvaneshwar29@gmail.com
else
echo $body | mail -s "jenkins backup failed on `date`" - c bhuvaneshwar29@gmail.com
fi
12 changes: 12 additions & 0 deletions hello.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
public class hello
{
private String name;

public void setName(String name) {
this.name = name;
}

public void printHello() {
System.out.println("Hello ! " + name);
}
}
22 changes: 22 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.mkyong.common</groupId>
<artifactId>SpringExamples</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>SpringExamples</name>
<url>http://maven.apache.org</url>
<dependencies>

<!-- Spring framework -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring</artifactId>
<version>2.5.6</version>
</dependency>

</dependencies>
</project>