Skip to content

Commit df9f870

Browse files
committed
Initial commit
0 parents  commit df9f870

20 files changed

+1069
-0
lines changed

.github/workflows/rubyonrails.yml

+70
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# Redmine plugin for OAuth
2+
#
3+
# Copyright © 2011-22 Karel Pičman <[email protected]>
4+
#
5+
# This program is free software; you can redistribute it and/or
6+
# modify it under the terms of the GNU General Public License
7+
# as published by the Free Software Foundation; either version 2
8+
# of the License, or (at your option) any later version.
9+
#
10+
# This program is distributed in the hope that it will be useful,
11+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
12+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13+
# GNU General Public License for more details.
14+
#
15+
# You should have received a copy of the GNU General Public License
16+
# along with this program; if not, write to the Free Software
17+
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18+
#
19+
# GitHub CI script
20+
21+
name: "GitHub CI"
22+
on:
23+
push:
24+
branches: ["master"]
25+
pull_request:
26+
branches: ["master"]
27+
jobs:
28+
plugin_tests:
29+
runs-on: ubuntu-latest
30+
env:
31+
RAILS_ENV: test
32+
NAME: redmine_oauth
33+
steps:
34+
- name: Install dependencies
35+
- name: Clone Redmine
36+
# Get the latest stable Redmine
37+
run: svn export https://svn.redmine.org/redmine/branches/5.0-stable/ /opt/redmine
38+
- name: Checkout code
39+
uses: actions/checkout@v3
40+
- name: Link the plugin
41+
# Link the plugin to the redmine folder
42+
run: |
43+
ln -s $(pwd) /opt/redmine/plugins/redmine_oauth
44+
- name: Install Ruby and gems
45+
uses: ruby/setup-ruby@0a29871fe2b0200a17a4497bae54fe5df0d973aa # v1.115.3
46+
with:
47+
bundler-cache: true
48+
ruby-version: '3.0'
49+
- name: Setup database
50+
# Configure the database
51+
run: |
52+
echo "test:" > /opt/redmine/config/database.yml
53+
echo " adapter: sqlite3" >> /opt/redmine/config/database.yml
54+
echo " database: db/redmine.sqlite3" >> /opt/redmine/config/database.yml
55+
- name: Install Redmine
56+
# Install Redmine
57+
run: |
58+
cd /opt/redmine
59+
bundle config set --local without 'rmagick development'
60+
bundle install
61+
bundle exec rake generate_secret_token
62+
bundle exec rake db:migrate
63+
bundle exec rake redmine:load_default_data
64+
env:
65+
REDMINE_LANG: en
66+
- name: Standard tests
67+
# Run the tests
68+
run: |
69+
cd /opt/redmine
70+
bundle exec rake redmine:plugins:test:functionals

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Gemfile.lock

CHANGELOG.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Changelog for Redmine OAuth
2+
==========================
3+
4+
1.0.0 *2022-09-16*
5+
------------------
6+
7+
Azure AD

CODE_OF_CONDUCT.md

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
6+
7+
## Our Standards
8+
9+
Examples of behavior that contributes to creating a positive environment include:
10+
11+
* Using welcoming and inclusive language
12+
* Being respectful of differing viewpoints and experiences
13+
* Gracefully accepting constructive criticism
14+
* Focusing on what is best for the community
15+
* Showing empathy towards other community members
16+
17+
Examples of unacceptable behavior by participants include:
18+
19+
* The use of sexualized language or imagery and unwelcome sexual attention or advances
20+
* Trolling, insulting/derogatory comments, and personal or political attacks
21+
* Public or private harassment
22+
* Publishing others' private information, such as a physical or electronic address, without explicit permission
23+
* Other conduct which could reasonably be considered inappropriate in a professional setting
24+
25+
## Our Responsibilities
26+
27+
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
28+
29+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
30+
31+
## Scope
32+
33+
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
34+
35+
## Enforcement
36+
37+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [email protected]. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
38+
39+
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
40+
41+
## Attribution
42+
43+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
44+
45+
[homepage]: http://contributor-covenant.org
46+
[version]: http://contributor-covenant.org/version/1/4/

CONTRIBUTING.md

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
## How to contribute to Redmine DMSF plugin
2+
3+
#### **Did you find a bug?**
4+
5+
* **Ensure the bug was not already reported** by searching on GitHub under [Issues](https://github.com/danmunn/redmine_dmsf/issues).
6+
* If you're unable to find an open issue addressing the problem, [open a new one](https://github.com/danmunn/redmine_dmsf/issues/new). Be sure to include a **title and clear description**, as much relevant information as possible, **Redmine and the plugin version**, a part of the **production.log** related to the issue and **screen-shots**.
7+
8+
#### **A wrong or missing translation?**
9+
10+
* Feel free to update language files (_config/locales/*.yml_) in your mother language or languages you are familiar with and send them back to us via a **pull request**.
11+
12+
#### **Do you want to patch the existing code?**
13+
14+
* Make a new fork of the current development branch (_devel_). Make your changes and [create a pull request](https://github.com/danmunn/redmine_dmsf/compare). Only pull requests into the **development branch** except those fixing serious errors will be accepted.

Gemfile

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# encoding: utf-8
2+
# frozen_string_literal: true
3+
#
4+
# Redmine plugin OAuth
5+
#
6+
# Karel Pičman <[email protected]>
7+
#
8+
# This program is free software; you can redistribute it and/or
9+
# modify it under the terms of the GNU General Public License
10+
# as published by the Free Software Foundation; either version 2
11+
# of the License, or (at your option) any later version.
12+
#
13+
# This program is distributed in the hope that it will be useful,
14+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
15+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16+
# GNU General Public License for more details.
17+
#
18+
# You should have received a copy of the GNU General Public License
19+
# along with this program; if not, write to the Free Software
20+
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21+
22+
source 'https://rubygems.org'
23+
24+
gem 'oauth2'
25+
gem 'jwt'

0 commit comments

Comments
 (0)