Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Gradle support for the Social login #2174

Closed
jdubois opened this issue Oct 19, 2015 · 9 comments
Closed

Add Gradle support for the Social login #2174

jdubois opened this issue Oct 19, 2015 · 9 comments
Assignees
Milestone

Comments

@jdubois
Copy link
Member

jdubois commented Oct 19, 2015

As @moifort added some conf in the pom.xml for feature #2155 they need to be copied to the Gradle build.
See https://github.com/jhipster/generator-jhipster/pull/2155/files

@atomfrede @moifort can you work together to solve this?

I'm currently merging #2155 it shouldn't be long!

@moifort
Copy link
Contributor

moifort commented Oct 19, 2015

Yes sorry I totally forget to make the Gradle build.

@moifort
Copy link
Contributor

moifort commented Oct 19, 2015

@atomfrede I am really sorry, I try to understand with mapstruct example but I don't know how Gradle work. This what we need to import for the social functionality (maven):

        <httpclient.version>4.5.1</httpclient.version>
        <spring-social-security.version>1.1.2.RELEASE</spring-social-security.version>
        <spring-social-google.version>1.0.0.RELEASE</spring-social-google.version>
        <spring-social-facebook.version>2.0.2.RELEASE</spring-social-facebook.version>
        <spring-social-twitter.version>1.1.1.RELEASE</spring-social-twitter.version>
        <!-- social -->
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpclient</artifactId>
            <version>${httpclient.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.social</groupId>
            <artifactId>spring-social-security</artifactId>
            <version>${spring-social-security.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.social</groupId>
            <artifactId>spring-social-google</artifactId>
            <version>${spring-social-google.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.social</groupId>
            <artifactId>spring-social-facebook</artifactId>
            <version>${spring-social-facebook.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.social</groupId>
            <artifactId>spring-social-twitter</artifactId>
            <version>${spring-social-twitter.version}</version>
        </dependency>

and this is the yo variable:
enableSocialSignIn

Can you help me?

@mraible
Copy link
Contributor

mraible commented Oct 19, 2015

For properties, those go in app/templates/_gradle.properties. For example

<% if (databaseType == 'sql') { %>
liquibase_slf4j_version=1.2.1
liquibase_core_version=3.4.1
liquibase_hibernate4_version=3.5<% } %><% if (databaseType == 'mongodb') { %>
embedmongo_spring_version=1.50.0
mongeez_version=0.9.4<% } %>
hibernate_validator_version=5.2.1.Final<% if (databaseType == 'cassandra') { %>
lz4_version=1.3.0<% } %>

For dependencies, those go in app/templates/_build.gradle, starting on line 93.

<% if (databaseType == 'sql') { %>
    compile group: 'org.springframework.boot', name: 'spring-boot-starter-data-jpa'<% } %><% if (searchEngine == 'elasticsearch') { %>
    compile group: 'org.springframework.boot', name: 'spring-boot-starter-data-elasticsearch'<% } %><% if (databaseType == 'mongodb') { %>
    compile group: 'org.springframework.boot', name: 'spring-boot-starter-data-mongodb'<% } %>

@atomfrede
Copy link
Member

@mraible you're absolutly right 👍
@moifort I've created a gist with the required additions to gradle.properties and build.gradle

See here: https://gist.github.com/atomfrede/d9f9f3f4115da1301152

@moifort
Copy link
Contributor

moifort commented Oct 19, 2015

Thank you guys!

@atomfrede
Copy link
Member

@moifort Can I assign this issue to you? You can integrate into your PR directly I guess.

@moifort moifort assigned moifort and unassigned atomfrede Oct 19, 2015
@moifort
Copy link
Contributor

moifort commented Oct 19, 2015

@atomfrede can you check if my modification is good?

@atomfrede
Copy link
Member

Looks good to me. Thanks!

@moifort
Copy link
Contributor

moifort commented Oct 19, 2015

Thank you!

@moifort moifort closed this as completed Oct 19, 2015
@jdubois jdubois modified the milestone: 2.23.0 Oct 21, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants