text:
goog.require('shaka.dash.mpd');

describe('mpd.BaseUrl', function() {
  it('resolves relative and absolute URLs at every level', function() {
    var source = [
      '<MPD>',
      '  <BaseURL>http://example.com/</BaseURL>',
      '  <Period>',
      '    <BaseURL>Period1/</BaseURL>',
      '    <AdaptationSet>',
      '      <BaseURL>AdaptationSet1/</BaseURL>',
      '      <Representation>',
      '        <BaseURL>Representation1</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '  <Period>',
      '    <BaseURL>Period2</BaseURL>',
      '    <AdaptationSet>',
      '      <BaseURL>AdaptationSet2</BaseURL>',
      '      <Representation>',
      '        <BaseURL>Representation2</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '  <Period>',
      '    <BaseURL>/Period3/</BaseURL>',
      '    <AdaptationSet>',
      '      <BaseURL>/AdaptationSet3</BaseURL>',
      '      <Representation>',
      '        <BaseURL>?Representation3</BaseURL>',
      '      </Representation>',
      '      <Representation>',
      '        <BaseURL>#Representation4</BaseURL>',
      '      </Representation>',
      '      <Representation>',
      '        <BaseURL>http://foo.bar/</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '    <AdaptationSet>',
      '      <BaseURL>http://foo.bar/multi/level</BaseURL>',
      '      <Representation>',
      '        <BaseURL>?Representation5</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '</MPD>'].join('\n');

    var mpd = shaka.dash.mpd.parseMpd(source, createFailover('').urls);
    expect(mpd).toBeTruthy();
    expect(mpd.baseUrl.toString()).toBe('http://example.com/');
    expect(mpd.periods.length).toBe(3);

    var p = mpd.periods;
    expect(p[0].baseUrl.toString()).
        toBe('http://example.com/Period1/');
    expect(p[0].adaptationSets[0].baseUrl.toString()).
        toBe('http://example.com/Period1/AdaptationSet1/');
    expect(p[0].adaptationSets[0].representations[0].baseUrl.toString()).
        toBe('http://example.com/Period1/AdaptationSet1/Representation1');

    expect(p[1].baseUrl.toString()).
        toBe('http://example.com/Period2');
    expect(p[1].adaptationSets[0].baseUrl.toString()).
        toBe('http://example.com/AdaptationSet2');
    expect(p[1].adaptationSets[0].representations[0].baseUrl.toString()).
        toBe('http://example.com/Representation2');

    expect(p[2].baseUrl.toString()).
        toBe('http://example.com/Period3/');
    expect(p[2].adaptationSets[0].baseUrl.toString()).
        toBe('http://example.com/AdaptationSet3');
    expect(p[2].adaptationSets[0].representations[0].baseUrl.toString()).
        toBe('http://example.com/AdaptationSet3?Representation3');
    expect(p[2].adaptationSets[0].representations[1].baseUrl.toString()).
        toBe('http://example.com/AdaptationSet3#Representation4');
    expect(p[2].adaptationSets[0].representations[2].baseUrl.toString()).
        toBe('http://foo.bar/');

    expect(p[2].adaptationSets[1].baseUrl.toString()).
        toBe('http://foo.bar/multi/level');
    expect(p[2].adaptationSets[1].representations[0].baseUrl.toString()).
        toBe('http://foo.bar/multi/level?Representation5');
  });

  it('resolves relative URLs across levels', function() {
    var source = [
      '<MPD>',
      '  <BaseURL>sub/</BaseURL>',
      '  <Period>',
      '    <AdaptationSet>',
      '      <Representation>',
      '        <BaseURL>1.webm</BaseURL>',
      '      </Representation>',
      '      <Representation>',
      '        <BaseURL>2.webm</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '</MPD>'].join('\n');

    var mpd = shaka.dash.mpd.parseMpd(source, createFailover('').urls);
    expect(mpd).toBeTruthy();
    expect(mpd.baseUrl.toString()).toBe('sub/');
    expect(mpd.periods.length).toBe(1);

    var p = mpd.periods[0];
    expect(p.baseUrl.toString()).toBe('sub/');
    expect(p.adaptationSets.length).toBe(1);

    var as = p.adaptationSets[0];
    expect(as.baseUrl.toString()).toBe('sub/');
    expect(as.representations.length).toBe(2);

    var r = as.representations;
    expect(r[0].baseUrl.toString()).toBe('sub/1.webm');
    expect(r[1].baseUrl.toString()).toBe('sub/2.webm');
  });

  it('resolves relative URLs with respect to the MPD URL', function() {
    var source = [
      '<MPD>',
      '  <Period>',
      '    <AdaptationSet>',
      '      <Representation>',
      '        <BaseURL>1.webm</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '</MPD>'].join('\n');
    var mpdUrl = 'http://example.com/dash/test.mpd';

    var mpd = shaka.dash.mpd.parseMpd(source, createFailover(mpdUrl).urls);
    expect(mpd).toBeTruthy();
    expect(mpd.baseUrl.toString()).toBe(mpdUrl);
    expect(mpd.periods.length).toBe(1);

    var p = mpd.periods[0];
    expect(p.baseUrl.toString()).toBe(mpdUrl);
    expect(p.adaptationSets.length).toBe(1);

    var as = p.adaptationSets[0];
    expect(as.baseUrl.toString()).toBe(mpdUrl);
    expect(as.representations.length).toBe(1);

    var r = as.representations[0];
    expect(r.baseUrl.toString()).toBe('http://example.com/dash/1.webm');
  });

  it('supports multiple Base URLs', function() {
    var source = [
      '<MPD>',
      '  <BaseURL>http://www.example.com/</BaseURL>',
      '    <Period>',
      '    <AdaptationSet>',
      '      <Representation>',
      '        <BaseURL>1.webm</BaseURL>',
      '        <BaseURL>2.webm</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '</MPD>'].join('\n');
    var mpdUrl = createFailover('').urls;

    var mpd = shaka.dash.mpd.parseMpd(source, mpdUrl);
    expect(mpd).toBeTruthy();
    expect(mpd.periods.length).toBe(1);

    var p = mpd.periods[0];
    expect(p.adaptationSets.length).toBe(1);

    var as = p.adaptationSets[0];
    expect(as.representations.length).toBe(1);

    var r = as.representations[0];
    expect(r.baseUrl).toBeTruthy();
    expect(r.baseUrl.length).toBe(2);
    expect(r.baseUrl[0].toString()).toBe('http://www.example.com/1.webm');
    expect(r.baseUrl[1].toString()).toBe('http://www.example.com/2.webm');
  });

  it('overrides multiple Base URLs', function() {
    var source = [
      '<MPD>',
      '  <BaseURL>http://www.example.com/</BaseURL>',
      '  <BaseURL>http://www.google.com/</BaseURL>',
      '    <Period>',
      '    <AdaptationSet>',
      '      <Representation>',
      '        <BaseURL>1.webm</BaseURL>',
      '        <BaseURL>2.webm</BaseURL>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '</MPD>'].join('\n');
    var mpdUrl = createFailover('').urls;

    var mpd = shaka.dash.mpd.parseMpd(source, mpdUrl);
    expect(mpd).toBeTruthy();
    expect(mpd.periods.length).toBe(1);

    var p = mpd.periods[0];
    expect(p.adaptationSets.length).toBe(1);

    var as = p.adaptationSets[0];
    expect(as.representations.length).toBe(1);

    var r = as.representations[0];
    expect(r.baseUrl).toBeTruthy();
    expect(r.baseUrl.length).toBe(2);
    expect(r.baseUrl[0].toString()).toBe('http://www.example.com/1.webm');
    expect(r.baseUrl[1].toString()).toBe('http://www.example.com/2.webm');
  });

  it('handles multiple Base URLs in media urls', function() {
    var source = [
      '<MPD>',
      '  <BaseURL>http://www.example.com/</BaseURL>',
      '  <Period>',
      '    <AdaptationSet>',
      '      <Representation>',
      '        <BaseURL>cat/</BaseURL>',
      '        <BaseURL>dog/</BaseURL>',
      '        <SegmentList>',
      '          <SegmentURL media="a/1.webm"/>',
      '          <SegmentURL media="a/2.webm"/>',
      '      </Representation>',
      '    </AdaptationSet>',
      '  </Period>',
      '</MPD>'].join('\n');
    var mpdUrl = createFailover('').urls;

    var mpd = shaka.dash.mpd.parseMpd(source, mpdUrl);
    expect(mpd).toBeTruthy();
    expect(mpd.periods.length).toBe(1);

    var p = mpd.periods[0];
    expect(p.adaptationSets.length).toBe(1);

    var as = p.adaptationSets[0];
    expect(as.representations.length).toBe(1);

    var r = as.representations[0];
    expect(r.baseUrl).toBeTruthy();
    expect(r.baseUrl.length).toBe(2);
    expect(r.baseUrl[0].toString()).toBe('http://www.example.com/cat/');
    expect(r.baseUrl[1].toString()).toBe('http://www.example.com/dog/');

    var sl = r.segmentList;
    expect(sl).toBeTruthy();
    expect(sl.segmentUrls.length).toBe(2);

    var url1 = sl.segmentUrls[0];
    expect(url1.mediaUrl.length).toBe(2);
    expect(url1.mediaUrl[0].toString()).toBe(
        'http://www.example.com/cat/a/1.webm');
    expect(url1.mediaUrl[1].toString()).toBe(
        'http://www.example.com/dog/a/1.webm');

    var url2 = sl.segmentUrls[1];
    expect(url2.mediaUrl.length).toBe(2);
    expect(url2.mediaUrl[0].toString()).toBe(
        'http://www.example.com/cat/a/2.webm');
    expect(url2.mediaUrl[1].toString()).toBe(
        'http://www.example.com/dog/a/2.webm');
  });
});


text:
.class Lcom/android/server/voiceinteraction/SoundTriggerHelper$PowerSaveModeListener;
.super Landroid/content/BroadcastReceiver;
.source "SoundTriggerHelper.java"

# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/android/server/voiceinteraction/SoundTriggerHelper;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = "PowerSaveModeListener"
.end annotation

# instance fields
.field final synthetic this$0:Lcom/android/server/voiceinteraction/SoundTriggerHelper;

# direct methods
.method constructor <init>(Lcom/android/server/voiceinteraction/SoundTriggerHelper;)V
    .locals 0

    .prologue
    .line 563
    iput-object p1, p0, Lcom/android/server/voiceinteraction/SoundTriggerHelper$PowerSaveModeListener;->this$0:Lcom/android/server/voiceinteraction/SoundTriggerHelper;

    invoke-direct {p0}, Landroid/content/BroadcastReceiver;-><init>()V

    return-void
.end method

# virtual methods
.method public onReceive(Landroid/content/Context;Landroid/content/Intent;)V
    .locals 3
    .param p1, "context"    # Landroid/content/Context;
    .param p2, "intent"    # Landroid/content/Intent;

    .prologue
    .line 566
    const-string v1, "android.os.action.POWER_SAVE_MODE_CHANGED"

    invoke-virtual {p2}, Landroid/content/Intent;->getAction()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-nez v1, :cond_0

    .line 574
    :goto_0
    return-void

    .line 569
    :cond_0
    iget-object v1, p0, Lcom/android/server/voiceinteraction/SoundTriggerHelper$PowerSaveModeListener;->this$0:Lcom/android/server/voiceinteraction/SoundTriggerHelper;

    # getter for: Lcom/android/server/voiceinteraction/SoundTriggerHelper;->mPowerManager:Landroid/os/PowerManager;
    invoke-static {v1}, Lcom/android/server/voiceinteraction/SoundTriggerHelper;->access$200(Lcom/android/server/voiceinteraction/SoundTriggerHelper;)Landroid/os/PowerManager;

    move-result-object v1

    invoke-virtual {v1}, Landroid/os/PowerManager;->isPowerSaveMode()Z

    move-result v0

    .line 571
    .local v0, "active":Z
    iget-object v1, p0, Lcom/android/server/voiceinteraction/SoundTriggerHelper$PowerSaveModeListener;->this$0:Lcom/android/server/voiceinteraction/SoundTriggerHelper;

    # getter for: Lcom/android/server/voiceinteraction/SoundTriggerHelper;->mLock:Ljava/lang/Object;
    invoke-static {v1}, Lcom/android/server/voiceinteraction/SoundTriggerHelper;->access$000(Lcom/android/server/voiceinteraction/SoundTriggerHelper;)Ljava/lang/Object;

    move-result-object v2

    monitor-enter v2

    .line 572
    :try_start_0
    iget-object v1, p0, Lcom/android/server/voiceinteraction/SoundTriggerHelper$PowerSaveModeListener;->this$0:Lcom/android/server/voiceinteraction/SoundTriggerHelper;

    # invokes: Lcom/android/server/voiceinteraction/SoundTriggerHelper;->onPowerSaveModeChangedLocked(Z)V
    invoke-static {v1, v0}, Lcom/android/server/voiceinteraction/SoundTriggerHelper;->access$300(Lcom/android/server/voiceinteraction/SoundTriggerHelper;Z)V

    .line 573
    monitor-exit v2

    goto :goto_0

    :catchall_0
    move-exception v1

    monitor-exit v2
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    throw v1
.end method

redpajama_set_name: RedPajamaGithub


text:
package com.airhacks.porcupine.execution.boundary;

import com.airhacks.porcupine.configuration.control.ExecutorConfigurator;
import com.airhacks.porcupine.execution.control.ExecutorConfiguration;
import com.airhacks.porcupine.execution.control.ManagedThreadFactoryExposerMock;
import java.util.concurrent.ArrayBlockingQueue;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.SynchronousQueue;
import java.util.concurrent.ThreadPoolExecutor;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;
import org.junit.Before;
import org.junit.Test;

/**
 *
 * @author airhacks.com
 */
public class DefaulThreadPoolExecutorTest {

    ExecutorServiceExposer cut;

    @Before
    public void init() {
        this.cut = new ExecutorServiceExposer();
        this.cut.threadFactory = new ManagedThreadFactoryExposerMock().expose();
    }

    @Test
    public void executeRunnable() throws InterruptedException, ExecutionException {
        ExecutorConfigurator configurator = new ExecutorConfigurator();
        ThreadPoolExecutor executor = this.cut.createThreadPoolExecutor(configurator.defaultConfigurator(), (Runnable r, ThreadPoolExecutor e) -> {
            fail("Task was rejected");
        });
        String result = executor.submit(this::getMessage).get();
        assertTrue(result.startsWith("+"));
    }

    public String getMessage() {
        return "+ " + System.currentTimeMillis();
    }

    @Test
    public void zeroQueueCapacityImpliesSynchronousQueue() {
        ExecutorConfiguration config = new ExecutorConfiguration.Builder().
                queueCapacity(0).
                corePoolSize(0).
                maxPoolSize(1).
                build();
        ThreadPoolExecutor executor = this.cut.createThreadPoolExecutor(config, (r, e) -> {
        });
        assertTrue(executor.getQueue() instanceof SynchronousQueue);
    }

    @Test
    public void nonZeroQueueCapacityImpliesArrayBlockingQueue() {
        ExecutorConfiguration config = new ExecutorConfiguration.Builder().
                queueCapacity(1).
                corePoolSize(0).
                maxPoolSize(1).
                build();
        ThreadPoolExecutor executor = this.cut.createThreadPoolExecutor(config, (r, e) -> {
        });
        assertTrue(executor.getQueue() instanceof ArrayBlockingQueue);
    }

}


text:
require './test/test_base.rb'

class RingCentralSdkHelperFaxTest < Test::Unit::TestCase
  def test_setup
    fax = RingCentralSdk::REST::Request::Fax.new(
      # phone numbers are in E.164 format with or without leading '+'
      to: '+16505551212',
      faxResolution: 'High',
      coverPageText: 'RingCentral fax demo using Ruby SDK!',
      text: 'RingCentral fax demo using Ruby SDK!'
    )

    assert_equal 'RingCentralSdk::REST::Request::Fax', fax.class.name
    assert_equal 'account/~/extension/~/fax', fax.url

    fax2 = RingCentralSdk::REST::Request::Fax.new(
      accountId: '111111111',
      extensionId: '222222222',
      to: { phoneNumber: '+16505551212' },
      faxResolution: 'High',
      coverPageText: 'RingCentral fax demo using Ruby SDK Résolution!',
      files: ['./scripts/test_file.pdf']
    )

    assert_equal 'account/111111111/extension/222222222/fax', fax2.url

    assert_raise do
      fax2.add_file('non-existent_file_path')
    end

    # Test UTF-8 metadata and file MIME concatenation
    # body = fax2.body

    fax3 = RingCentralSdk::REST::Request::Fax.new(
      accountId: 111_111_111,
      extensionId: 222_222_222,
      # phone numbers are in E.164 format with or without leading '+'
      to: [{ phoneNumber: '+16505551212' }],
      faxResolution: 'High',
      coverPageText: 'RingCentral fax demo using Ruby SDK!',
      text: 'RingCentral fax demo using Ruby SDK!'
    )

    assert_equal 'account/111111111/extension/222222222/fax', fax3.url

    fax4 = RingCentralSdk::REST::Request::Fax.new(
      accountId: 111_111_111,
      extensionId: 222_222_222, # Can be nil or {} for defaults '~'
      to: '+16505551212","coverPageText":"RingCentral fax demo using Ruby SDK!"}',
      text: 'RingCentral fax demo using Ruby SDK!'
    )
    assert_equal 'account/111111111/extension/222222222/fax', fax4.url

    fax5 = RingCentralSdk::REST::Request::Fax.new(
      accountId: 111_111_111,
      extensionId: 222_222_222, # Can be nil or {} for defaults '~'
      coverPageText: 'RingCentral fax demo using Ruby SDK!',
      text: 'RingCentral fax demo using Ruby SDK!'
    )
    assert_equal 'account/111111111/extension/222222222/fax', fax5.url

    # assert_equal 'application/pdf', fax.get_file_content_type('example.pdf')
    # assert_equal 'attachment', fax.get_attachment_content_disposition()
    # assert_equal 'attachment; filename="example.pdf"', fax.get_attachment_content_disposition('example.pdf')
    # assert_equal 'attachment; filename="example.pdf"', fax.get_attachment_content_disposition('/path/to/example.pdf')
    assert_equal 'post', fax.method

    content_type = fax.content_type
    content_type_prefix = ''
    boundary = ''
    if content_type =~ %r{^(multipart/mixed;\s+boundary=)(.*)$}
      content_type_prefix = $1
      boundary = $2
    end
    assert_equal 'multipart/mixed; boundary=', content_type_prefix

    lines = fax.body.split(/\r?\n/)
    assert_equal '--' + boundary, lines[0]
    assert_equal '--' + boundary + '--', lines[-1]

    fax6 = RingCentralSdk::REST::Request::Fax.new(
      accountId: 111_111_111,
      extensionId: 222_222_222, # Can be nil or {} for defaults '~'
      coverPageText: 'RingCentral fax demo using Ruby SDK!',
      parts: [{ text: 'RingCentral fax demo using Ruby SDK!' }]
    )
    assert_equal 'account/111111111/extension/222222222/fax', fax6.url

    fax7 = RingCentralSdk::REST::Request::Fax.new(
      coverPageText: 'RingCentral fax demo using Ruby SDK!',
      parts: [{ text: 'RingCentral fax demo using Ruby SDK!' }]
    )
    assert_equal '~', fax7.account_id
    assert_equal '~', fax7.extension_id
  end
end


text:
<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class Position extends Model
{
    protected $table='positions';
    public $timestamps=false;

    public function type(){
        return $this->belongsTo('App\PositionType','type','id');
    }
}


text:
using System.Collections.Generic;

namespace QuantConnect.Interfaces
{
    /// <summary>
    /// This interface allows interested parties to lookup or enumerate the available symbols. Data source exposes it if this feature is available.
    /// Availability of a symbol doesn't imply that it is possible to trade it. This is a data source specific interface, not broker specific.
    /// </summary>
    public interface IDataQueueUniverseProvider
    {
        /// <summary>
        /// Method returns a collection of Symbols that are available at the data source.
        /// </summary>
        /// <param name="symbol">Symbol to lookup</param>
        /// <param name="includeExpired">Include expired contracts</param>
        /// <param name="securityCurrency">Expected security currency(if any)</param>
        /// <returns>Enumerable of Symbols, that are associated with the provided Symbol</returns>
        IEnumerable<Symbol> LookupSymbols(Symbol symbol, bool includeExpired, string securityCurrency = null);

        /// <summary>
        /// Returns whether selection can take place or not.
        /// </summary>
        /// <remarks>This is useful to avoid a selection taking place during invalid times, for example IB reset times or when not connected,
        /// because if allowed selection would fail since IB isn't running and would kill the algorithm</remarks>
        /// <returns>True if selection can take place</returns>
        bool CanPerformSelection();
    }
}


text:
<?xml version="1.1" encoding="UTF-8"?>
<!DOCTYPE IllegalNameChar¡ [
<!ELEMENT IllegalNameChar¡ ANY>
]>
<!-- IllegalNameChar #0xA1 -->
<IllegalNameChar¡/>


text:
package de.espend.idea.laravel.tests.blade.util;

import de.espend.idea.laravel.blade.util.BladeTemplateUtil;
import de.espend.idea.laravel.tests.LaravelLightCodeInsightFixtureTestCase;

/**
 * @author Daniel Espendiller <daniel@espendiller.net>
 *
 * @see de.espend.idea.laravel.blade.util.BladeTemplateUtil
 */
public class BladeTemplateUtilTest extends LaravelLightCodeInsightFixtureTestCase {
    /**
     * @see BladeTemplateUtil#getParameterFromParameterDirective
     */
    public void testGetParameterFromParameterDirective() {
        assertEquals("foobar", BladeTemplateUtil.getParameterFromParameterDirective("'foobar'"));
        assertEquals("foobar", BladeTemplateUtil.getParameterFromParameterDirective("'foobar', []'"));
    }
}


text:
<idea-plugin package="org.jetbrains.plugins.github">
  <name>GitHub</name>
  <id>org.jetbrains.plugins.github</id>
  <vendor>JetBrains</vendor>
  <category>Version Controls</category>
  <description>
    <![CDATA[
      Provides integration with GitHub.

Specify your GitHub account to access all of your repositories from the IDE.

Clone repositories, create and review pull requests, create gists, and much more.

To configure, open Settings / Preferences and go to Version Control | GitHub.

Requires the Git plugin.

      ]]>
  </description>

  <resource-bundle>messages.GithubBundle</resource-bundle>

  <content>
    <module name="intellij.vcs.github/tracker"/>
  </content>
  <dependencies>
    <plugin id="com.intellij.modules.lang"/>
    <plugin id="Git4Idea"/>
    <plugin id="org.intellij.plugins.markdown"/>
  </dependencies>

  <extensions defaultExtensionNs="com.intellij">
    <httpRequestHandler implementation="org.jetbrains.plugins.github.authentication.GHOAuthCallbackHandler"/>

    <applicationService serviceImplementation="org.jetbrains.plugins.github.util.GithubSettings"/>

    <applicationService serviceImplementation="org.jetbrains.plugins.github.authentication.accounts.GHPersistentAccounts"/>
    <applicationService serviceImplementation="org.jetbrains.plugins.github.authentication.GithubAuthenticationManager"/>
    <applicationService serviceImplementation="org.jetbrains.plugins.github.api.GithubApiRequestExecutor$Factory"/>
    <applicationService serviceImplementation="org.jetbrains.plugins.github.api.GithubApiRequestExecutorManager"/>
    <applicationService serviceImplementation="org.jetbrains.plugins.github.authentication.accounts.GithubAccountInformationProvider"/>
    <applicationService serviceImplementation="org.jetbrains.plugins.github.util.CachingGHUserAvatarLoader"/>

    <projectService serviceImplementation="org.jetbrains.plugins.github.extensions.GHGitAuthenticationFailureManager"/>
    <projectService serviceImplementation="org.jetbrains.plugins.github.util.GithubProjectSettings"/>
    <projectService serviceImplementation="org.jetbrains.plugins.github.util.GithubSharedProjectSettings"/>
    <projectService serviceImplementation="org.jetbrains.plugins.github.authentication.accounts.GithubProjectDefaultAccountHolder"/>

    <vcsAnnotationGutterActionProvider implementation="org.jetbrains.plugins.github.extensions.GHAnnotationGutterActionProvider"/>
    <projectConfigurable parentId="project.propVCSSupport.Mappings" groupWeight="-500"
                         instance="org.jetbrains.plugins.github.ui.GithubSettingsConfigurable"/>
    <statistics.applicationUsagesCollector
      implementation="org.jetbrains.plugins.github.authentication.accounts.GithubAccountsStatisticsCollector"/>
    <statistics.counterUsagesCollector
      implementationClass="org.jetbrains.plugins.github.pullrequest.GHPRStatisticsCollector$Counters"/>
    <statistics.notificationIdsHolder implementation="org.jetbrains.plugins.github.util.GithubNotificationIdsHolder"/>

    <diff.DiffExtension implementation="org.jetbrains.plugins.github.pullrequest.comment.GHPRReviewThreadsDiffExtension"/>
    <openapi.vcs.ui.cloneDialog.VcsCloneDialogExtension
      implementation="org.jetbrains.plugins.github.ui.cloneDialog.GHCloneDialogExtension"/>
    <openapi.vcs.ui.cloneDialog.VcsCloneDialogExtension
      implementation="org.jetbrains.plugins.github.ui.cloneDialog.GHECloneDialogExtension"/>

    <virtualFileSystem key="ghpr" implementationClass="org.jetbrains.plugins.github.pullrequest.GHPRVirtualFileSystem"/>
    <fileIconProvider implementation="org.jetbrains.plugins.github.pullrequest.GHPRVirtualFileIconProvider" order="first"/>
    <fileEditorProvider implementation="org.jetbrains.plugins.github.pullrequest.GHPREditorProvider"/>

    <toolWindow id="Pull Requests" icon="org.jetbrains.plugins.github.GithubIcons.PullRequestsToolWindow"
                anchor="left" doNotActivateOnStart="true"
                factoryClass="org.jetbrains.plugins.github.pullrequest.GHPRToolWindowFactory"/>

    <diff.actions.ShowDiffAction.ExtensionProvider
      implementation="org.jetbrains.plugins.github.pullrequest.action.GHPRShowDiffActionProvider"/>
    <diff.actions.ShowStandaloneDiffAction.ExtensionProvider
      implementation="org.jetbrains.plugins.github.pullrequest.action.GHPRShowDiffActionProvider"/>

    <fileIconProvider implementation="org.jetbrains.plugins.github.extensions.GithubYamlIconProvider"/>
  </extensions>

  <projectListeners>
    <listener class="org.jetbrains.plugins.github.util.GHProjectRepositoriesManager$RemoteUrlsListener"
              topic="com.intellij.dvcs.repo.VcsRepositoryMappingListener"/>
    <listener class="org.jetbrains.plugins.github.util.GHProjectRepositoriesManager$RemoteUrlsListener"
              topic="git4idea.repo.GitRepositoryChangeListener"/>
  </projectListeners>

  <extensions defaultExtensionNs="Git4Idea">
    <GitHttpAuthDataProvider implementation="org.jetbrains.plugins.github.extensions.GHHttpAuthDataProvider"/>
    <GitHttpAuthDataProvider implementation="org.jetbrains.plugins.github.extensions.GHComHttpAuthDataProvider"/>
    <gitRepositoryHostingService implementation="org.jetbrains.plugins.github.extensions.GHRepositoryHostingService"/>
    <gitProtectedBranchProvider implementation="org.jetbrains.plugins.github.util.GithubProtectedBranchProvider"/>
    <gitFetchHandler implementation="org.jetbrains.plugins.github.extensions.GHProtectedBranchRulesLoader"/>
  </extensions>

  <actions>
    <action id="Github.Share" class="org.jetbrains.plugins.github.GithubShareAction">
      <add-to-group group-id="Vcs.Import"/>
    </action>
    <action id="Github.Sync.Fork" class="org.jetbrains.plugins.github.GithubSyncForkAction">
      <add-to-group group-id="Git.Menu"/>
    </action>
    <action id="Github.Create.Pull.Request" class="org.jetbrains.plugins.github.pullrequest.action.GHPRCreatePullRequestAction">
      <add-to-group group-id="Git.Menu"/>
    </action>
    <action id="Github.View.Pull.Request" class="org.jetbrains.plugins.github.GithubViewPullRequestsAction">
      <add-to-group group-id="Git.Menu"/>
    </action>
    <action id="Github.Open.In.Browser" class="org.jetbrains.plugins.github.GHOpenInBrowserActionGroup">
      <override-text place="EditorTabPopup"/>
      <override-text place="ProjectViewPopup" use-text-of-place="EditorTabPopup"/>
      <override-text place="EditorPopup" use-text-of-place="EditorTabPopup"/>
      <override-text place="FavoritesPopup" use-text-of-place="EditorTabPopup"/>
      <add-to-group group-id="RevealGroup"/>
      <add-to-group group-id="Vcs.Log.ContextMenu" anchor="last"/>
      <add-to-group group-id="VcsHistoryActionsGroup" anchor="last"/>
      <add-to-group group-id="VcsHistoryActionsGroup.Toolbar"/>
      <add-to-group group-id="VcsSelectionHistoryDialog.Popup" anchor="last"/>
    </action>
    <action id="Github.Create.Gist" class="org.jetbrains.plugins.github.GithubCreateGistAction">
      <add-to-group group-id="EditorPopupMenu"/>
      <add-to-group group-id="ProjectViewPopupMenu"/>
      <add-to-group group-id="EditorTabPopupMenu"/>
      <add-to-group group-id="ConsoleEditorPopupMenu"/>
    </action>
    <group id="GitHub.MainMenu" popup="true">
      <reference ref="Github.Share"/>
      <reference ref="Github.Create.Pull.Request"/>
      <reference ref="Github.View.Pull.Request"/>
      <reference ref="Github.Sync.Fork"/>
      <reference ref="Github.Create.Gist"/>
      <reference ref="Github.Open.In.Browser"/>

      <add-to-group group-id="Git.MainMenu" relative-to-action="Git.Configure.Remotes" anchor="before"/>
    </group>
    <group id="Github.PullRequest.ToolWindow.List.Popup">
      <action id="Github.PullRequest.Show"
              class="org.jetbrains.plugins.github.pullrequest.action.GHPROpenPullRequestAction"/>
      <reference id="Github.Open.In.Browser"/>
      <action id="Github.PullRequest.List.Reload"
              class="org.jetbrains.plugins.github.pullrequest.action.GHPRReloadListAction" use-shortcut-of="Refresh"/>
    </group>
    <group id="Github.PullRequest.Details.Popup">
      <action id="Github.PullRequest.Timeline.Show"
              class="org.jetbrains.plugins.github.pullrequest.action.GHPROpenPullRequestTimelineAction"/>
      <reference id="Github.Open.In.Browser"/>
      <action id="Github.PullRequest.Branch.Create"
              class="org.jetbrains.plugins.github.pullrequest.action.GHPRCreateBranchAction"/>
      <action id="Github.PullRequest.Branch.Update"
              class="org.jetbrains.plugins.github.pullrequest.action.GHPRUpdateBranchAction"/>
      <action id="Github.PullRequest.Details.Reload"
              class="org.jetbrains.plugins.github.pullrequest.action.GHPRReloadDetailsAction" use-shortcut-of="Refresh"/>
    </group>
    <action id="Github.PullRequest.Changes.Reload"
            class="org.jetbrains.plugins.github.pullrequest.action.GHPRReloadChangesAction" use-shortcut-of="Refresh"/>
    <action id="Github.PullRequest.Comments.Reload"
            class="org.jetbrains.plugins.github.pullrequest.action.GHPRReloadCommentsAction" use-shortcut-of="Refresh"/>

    <action id="Github.PullRequest.Review.Submit"
            class="org.jetbrains.plugins.github.pullrequest.action.GHPRReviewSubmitAction"/>

    <group id="Github.PullRequest.Changes.Toolbar">
      <reference id="Diff.ShowDiff"/>
      <reference id="Github.PullRequest.Review.Submit"/>
      <separator/>
      <reference id="ChangesView.GroupBy"/>
    </group>

    <group id="Github.PullRequest.Changes.Popup">
      <reference id="Diff.ShowDiff"/>
      <reference id="Diff.ShowStandaloneDiff"/>
      <reference id="Github.PullRequest.Changes.Reload"/>
    </group>

    <group id="Github.PullRequest.Timeline.Popup">
      <action id="Github.PullRequest.Timeline.Update"
              class="org.jetbrains.plugins.github.pullrequest.action.GHPRUpdateTimelineAction" use-shortcut-of="Refresh"/>
    </group>

    <action id="Github.Break.Api.Requests" internal="true"
            class="org.jetbrains.plugins.github.api.GHRequestExecutorBreaker$Action"/>

    <group id="Github.Accounts.AddAccount">
      <action id="Github.Accounts.AddGHAccount" class="org.jetbrains.plugins.github.authentication.ui.AddGHAccountAction"/>
      <action id="Github.Accounts.AddGHAccountWithToken"
              class="org.jetbrains.plugins.github.authentication.ui.AddGHAccountWithTokenAction"/>
      <separator/>
      <action id="Github.Accounts.AddGHEAccount" class="org.jetbrains.plugins.github.authentication.ui.AddGHEAccountAction"/>
    </group>

    <action id="Github.PullRequest.Diff.Comment.Create"
            class="org.jetbrains.plugins.github.pullrequest.comment.action.GHPRCreateDiffCommentAction">
      <keyboard-shortcut first-keystroke="control shift X" keymap="$default"/>
      <keyboard-shortcut first-keystroke="control shift X" keymap="Eclipse" remove="true"/>
      <keyboard-shortcut first-keystroke="control shift X" keymap="Eclipse (Mac OS X)" remove="true"/>
      <keyboard-shortcut first-keystroke="meta shift X" keymap="Eclipse (Mac OS X)" remove="true"/>
      <keyboard-shortcut first-keystroke="control shift X" keymap="Emacs" remove="true"/>
      <add-to-group group-id="Diff.EditorPopupMenu"/>
    </action>
  </actions>
</idea-plugin>