Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/adempiere/LVE.git
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosaparadam committed Aug 24, 2024
2 parents 68caf23 + b58ceca commit 9db41ea
Show file tree
Hide file tree
Showing 11 changed files with 469 additions and 105 deletions.
38 changes: 0 additions & 38 deletions .github/workflows/build_with_gradle.yml

This file was deleted.

44 changes: 44 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# This is a basic workflow to help you get started with Actions
# This file was contributed by Carlos Parada and Yamel Senih from ERP Consultores y Asociados, C.A

name: Continuous Integration with Gradle

# Controls when the action will run.
on:
# Triggers the workflow on push or pull request events but only for the develop branch
push:
branches:
- '*' # matches every branch that doesn't contain a '/'
- '*/*' # matches every branch containing a single '/'
- '**' # matches every branch
pull_request:
branches:
- '*' # matches every branch that doesn't contain a '/'
- '*/*' # matches every branch containing a single '/'
- '**' # matches every branch

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:

build-ci:
name: Build Project
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v3

- name: Set up Java JDK 11
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-package: 'jdk'
java-version: 11
architecture: x64

- name: Build with Gradle
uses: gradle/gradle-build-action@v2
with:
gradle-version: 8.0.1
arguments: build
env:
ADEMPIERE_LIBRARY_VERSION: 'build'
69 changes: 69 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# This is a basic workflow to help you get started with Actions
# This file was contributed by Carlos Parada and Yamel Senih from ERP Consultores y Asociados, C.A

name: Publish With gradle to maven central

# Controls when the action will run.
on:
# Triggers the workflow on push or pull request events but only for the develop branch
release:
types:
- published

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:

publish-sonatype:
name: Publish Project (Sonatype)
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Set up Java JDK 11
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-package: 'jdk'
java-version: 11
architecture: x64

- name: Build with Gradle
uses: gradle/gradle-build-action@v3
with:
gradle-version: 8.0.2
arguments: publish
env:
ORG_GRADLE_PROJECT_deployVersion: ${{ github.event.release.tag_name }}
ORG_GRADLE_PROJECT_deployPublishUrl: ${{ secrets.DEPLOY_PUBLISH_SONATYPE_URL }}
ORG_GRADLE_PROJECT_deploySigningKey: ${{ secrets.PGP_SECRET }}
ORG_GRADLE_PROJECT_deploySigningPassword: ${{ secrets.PGP_PASSPHRASE }}
ORG_GRADLE_PROJECT_deployUsername: ${{ secrets.OSSRH_USERNAME }}
ORG_GRADLE_PROJECT_deployPassword: ${{ secrets.OSSRH_TOKEN }}
publish-github:
name: Publish Project (Github)
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Set up Java JDK 11
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-package: 'jdk'
java-version: 11
architecture: x64

- name: Build with Gradle
uses: gradle/gradle-build-action@v3
with:
gradle-version: 8.0.2
arguments: publish
env:
ORG_GRADLE_PROJECT_deployVersion: ${{ github.event.release.tag_name }}
ORG_GRADLE_PROJECT_deployPublishUrl: ${{ secrets.DEPLOY_PUBLISH_GITHUB_URL }}
ORG_GRADLE_PROJECT_deploySigningKey: ${{ secrets.PGP_SECRET }}
ORG_GRADLE_PROJECT_deploySigningPassword: ${{ secrets.PGP_PASSPHRASE }}
ORG_GRADLE_PROJECT_deployUsername: "${{ github.actor }}"
ORG_GRADLE_PROJECT_deployPassword: "${{ secrets.DEPLOY_TOKEN }}"
38 changes: 0 additions & 38 deletions .github/workflows/publish_with_gradle.yml

This file was deleted.

74 changes: 48 additions & 26 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
apply plugin: 'java-library'
apply plugin: 'maven-publish'
apply plugin: 'signing'
plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
}

sourceCompatibility = 1.11
def baseVersion = '3.9.4'
def baseGroupId = 'io.github.adempiere'

repositories {
mavenLocal()
Expand All @@ -15,26 +20,22 @@ allprojects {
sourceCompatibility = 1.11
targetCompatibility = 1.11

def baseVersion = '3.9.4'
def baseGroupId = 'io.github.adempiere'
def customGroupId = System.getenv("ADEMPIERE_LIBRARY_GROUP")

dependencies {
implementation fileTree(
api fileTree(
dir: 'lib',
include: [
'*.jar'
]
)
// ADempiere Core
implementation "${baseGroupId}:human-resource-and-payroll:${baseVersion}"
implementation "${baseGroupId}:store:${baseVersion}"
api "${baseGroupId}:human-resource-and-payroll:${baseVersion}"
api "${baseGroupId}:store:${baseVersion}"
// https://search.maven.org/artifact/javax.mail/javax.mail-api/1.6.2/jar
implementation 'javax.mail:javax.mail-api:1.6.2'
api 'javax.mail:javax.mail-api:1.6.2'
// http://xml.apache.org/commons/#external
implementation 'xml-apis:xml-apis:2.0.2'
implementation "${baseGroupId}:withholding-engine:adempiere-3.9.4-1.3.2"
implementation 'io.vavr:vavr:0.10.4'
api 'xml-apis:xml-apis:2.0.2'
api "${baseGroupId}:withholding-engine:adempiere-3.9.4-1.3.2"
api 'io.vavr:vavr:0.10.4'
}

sourceSets {
Expand All @@ -50,8 +51,10 @@ java {
withSourcesJar()
}


def entityType = 'LVE'
version = System.getenv("ADEMPIERE_LIBRARY_VERSION") ?: "local-1.0.0"
group = "io.github.adempiere"
version = findProperty("deployVersion") ?: "local-1.0.0"

jar {
manifest {
Expand All @@ -63,19 +66,21 @@ jar {

publishing {
repositories {
mavenLocal()

maven {
url = "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/"
url = findProperty("deployPublishUrl") ?: System.properties['deploy.publish_url']
credentials {
username = findProperty("sonatypeUsername")
password = findProperty("sonatypePassword")
username = findProperty("deployUsername") ?: System.properties['deploy.user']
password = findProperty("deployPassword") ?: System.properties['deploy.token']
}
}
}
publications {
mavenJava(MavenPublication) {
groupId 'io.github.adempiere'
artifactId 'location-venezuela'
version
groupId = group
artifactId = 'location-venezuela'
version = version
from components.java
pom {
name = 'ADempiere Venezuela Location'
Expand All @@ -95,18 +100,35 @@ publishing {
}
}
scm {
connection = 'scm:git:git://github.com/adempiere/LVE.git'
developerConnection = 'scm:git:ssh://github.com/adempiere/LVE.git'
url = 'http://github.com/adempiere/LVE'
connection = 'scm:git:git://github.com/adempiere/lve.git'
developerConnection = 'scm:git:ssh://github.com/adempiere/lve.git'
url = 'http://github.com/adempiere/lve'
}
}
}
}
}


task cleanBuildPublishLocal(type: GradleBuild) {
tasks = ['clean', 'build', 'publishToMavenLocal']
}


signing {
def signingKey = findProperty("signingKey")
def signingPassword = findProperty("signingPassword")
def isReleaseVersion = !version.toString().startsWith("local") && !version.toString().endsWith("-SNAPSHOT")

sign configurations.archives

setRequired {
// signing is required if this is a release version and the artifacts are to be published
// do not use hasTask() as this require realization of the tasks that maybe are not necessary
(isReleaseVersion || version.toString().equals("build")) && gradle.taskGraph.allTasks.any {
it.equals(PublishToMavenRepository)
}
}
def signingKey = findProperty("deploySigningKey")
def signingPassword = findProperty("deploySigningPassword")
useInMemoryPgpKeys(signingKey, signingPassword)
sign publishing.publications.mavenJava
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/*************************************************************************************
* Product: Adempiere ERP & CRM Smart Business Solution *
* Copyright (C) 2012-2018 E.R.P. Consultores y Asociados, C.A. *
* Contributor(s): Yamel Senih ysenih@erpya.com *
* This program is free software: you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation, either version 3 of the License, or *
* (at your option) any later version. *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* You should have received a copy of the GNU General Public License *
* along with this program. If not, see <https://www.gnu.org/licenses/>. *
************************************************************************************/
package org.erpya.lve.bank.imp;

import org.spin.util.impexp.BankStatementHandler;
import org.spin.util.impexp.BankTransactionAbstract;

/**
* Bancaribe separado por punto y coma
* @author Yamel Senih, ysenih@erpya.com , http://www.erpya.com
* <li>
* @see https://github.com/adempiere/adempiere/issues/1701
*/
public final class Bancaribe_Loader_Ssv extends BankStatementHandler {
@Override
protected BankTransactionAbstract getBankTransactionInstance() {
return new Bancaribe_Ssv();
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
/*************************************************************************************
* Product: Adempiere ERP & CRM Smart Business Solution *
* Copyright (C) 2012-2018 E.R.P. Consultores y Asociados, C.A. *
* Contributor(s): Yamel Senih ysenih@erpya.com *
* This program is free software: you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation, either version 3 of the License, or *
* (at your option) any later version. *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* You should have received a copy of the GNU General Public License *
* along with this program. If not, see <https://www.gnu.org/licenses/>. *
************************************************************************************/
package org.erpya.lve.bank.imp;

/**
* Formato de Bancaribe separado por punto y coma ";"
* @author Yamel Senih, ysenih@erpya.com , http://www.erpya.com
* @see https://github.com/adempiere/LVE/issues/61
*/
public class Bancaribe_Ssv extends Bancaribe_v1 {
/** Start Column Index */
private static final String SEPARATOR = ";";

@Override
public String getSeparator() {
return SEPARATOR;
}
}
Loading

0 comments on commit 9db41ea

Please sign in to comment.