Created
April 27, 2018 16:37
-
-
Save jasonrobot/07f8ebf3210baba98479671d5f4db495 to your computer and use it in GitHub Desktop.
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
<project name="MyProject" default="dist" basedir="."> | |
<description> | |
simple example build file | |
</description> | |
<!-- set global properties for this build --> | |
<property name="src" location="src"/> | |
<property name="build" location="build"/> | |
<property name="dist" location="dist"/> | |
<target name="init"> | |
<!-- Create the time stamp --> | |
<tstamp/> | |
<!-- Create the build directory structure used by compile --> | |
<mkdir dir="${build}"/> | |
</target> | |
<target name="compile" depends="init" | |
description="compile the source"> | |
<!-- Compile the Java code from ${src} into ${build} --> | |
<javac srcdir="${src}" destdir="${build}"/> | |
</target> | |
<target name="dist" depends="compile" | |
description="generate the distribution"> | |
<!-- Create the distribution directory --> | |
<mkdir dir="${dist}/lib"/> | |
<!-- Put everything in ${build} into the MyProject-${DSTAMP}.jar file --> | |
<jar jarfile="${dist}/lib/MyProject-${DSTAMP}.jar" basedir="${build}"/> | |
</target> | |
<target name="clean" | |
description="clean up"> | |
<!-- Delete the ${build} and ${dist} directory trees --> | |
<delete dir="${build}"/> | |
<delete dir="${dist}"/> | |
</target> | |
</project> |
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
apply plugin: 'java' | |
compileTestJava { | |
sourceCompatibility = JavaVersion.VERSION_1_8 | |
targetCompatibility = JavaVersion.VERSION_1_8 | |
} | |
apply plugin: 'eclipse' | |
apply plugin: 'idea' | |
ext { | |
seleniumVersion = '3.6.0' | |
} | |
sourceSets { | |
main { | |
java { | |
srcDirs = ['src'] | |
} | |
resources { | |
srcDirs = ['etc', 'suites'] | |
} | |
} | |
} | |
repositories { | |
jcenter() | |
} | |
dependencies { | |
compile group: 'org.testng', name: 'testng', version: '6.9.12' | |
compile group: 'org.seleniumhq.selenium', name: 'selenium-firefox-driver', version: seleniumVersion | |
compile group: 'org.seleniumhq.selenium', name: 'selenium-chrome-driver', version: seleniumVersion | |
compile group: 'org.seleniumhq.selenium', name: 'selenium-api', version: seleniumVersion | |
compile group: 'org.seleniumhq.selenium', name: 'selenium-java', version: seleniumVersion | |
compile 'javax.mail:mail:1.4.7' | |
compile 'com.google.code.gson:gson:2.5' | |
compile 'net.sf.jopt-simple:jopt-simple:4.9' | |
} | |
jar { | |
from { | |
(configurations.runtime).collect { | |
it.isDirectory() ? it : zipTree(it) | |
} | |
} | |
manifest { | |
attributes("Main-Class": "com.ourapp.app.tools.Main" ) | |
} | |
baseName = 'ourapp-selenium' | |
} | |
compileJava { | |
options.encoding = "UTF-8" | |
}⏎ |
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
CC=gcc | |
RM=rm -f | |
SRC_DIR := src | |
OBJ_DIR := obj | |
INC_FILES := $(wildcard $(SRC_DIR)/*.h) | |
SRC_FILES := $(wildcard $(SRC_DIR)/*.c) | |
OBJ_FILES := $(patsubst $(SRC_DIR)/%.c,$(OBJ_DIR)/%.o,$(SRC_FILES)) | |
$_LDFLAGS := -g -Wall | |
$_CFLAGS := -g -Wall | |
$(OBJ_DIR)/%.o: $(SRC_DIR)/%.c | |
$(CC) $(CFLAGS) -g -c -o $@ $< | |
dice: $(OBJ_FILES) | |
$(CC) $(LDFLAGS) -g -o $@ $(OBJ_FILES) | |
# learning is hard! | |
test: $(OBJ_FILES) | |
@echo $@ | |
@echo $^ | |
@echo $(SRC_DIR) | |
@echo $(SRC_FILES) | |
@echo $(wildcard $(SRC_DIR)/*.c) | |
@echo $(OBJ_DIR) | |
@echo $(OBJ_FILES) | |
@echo $(CFLAGS) | |
@echo $(LDFLAGS) | |
clean: | |
$(RM) $(OBJ_FILES) | |
cleanall: clean | |
$(RM) dice |
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
<project> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>com.mycompany.app</groupId> | |
<artifactId>my-app</artifactId> | |
<version>1</version> | |
</project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment