Skip to content

Commit

Permalink
Merge pull request #22 from Mr0grog/21-update-core-v0.12.1
Browse files Browse the repository at this point in the history
Update EditorConfig-Core v0.12.1
  • Loading branch information
Mr0grog committed May 26, 2016
2 parents e1c8cde + bec9707 commit ed84b9b
Show file tree
Hide file tree
Showing 13 changed files with 137 additions and 23 deletions.
4 changes: 2 additions & 2 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
Copyright (c) 2012 Rob Brackett
Copyright (c) 2012-2016 Rob Brackett

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

This code relies on a library called "editorconfig-core". Its license can be found in the file "LICENSE-editorconfig-core".
This code relies on the "editorconfig-core" and "pcre" libraries. Their licenses can be found in the files "LICENSE-editorconfig-core" and "LICENSE-pcre".
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,9 @@ TextMate 2
----------

While this plug-in does support the TextMate 2 Alpha, please keep in mind that alpha software is subject to great change. It could break in future releases of TextMate. If this happens, please file an issue: https://github.com/Mr0grog/editorconfig-textmate/issues


License
-------

This plug-in is open source. It is copyright (c) 2012-2016 Rob Brackett and licensed under the MIT license. The full license text is in the `LICENSE` file.
10 changes: 4 additions & 6 deletions editorconfig-textmate.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@
CB47C59415C0538700E068C7 /* Sources */,
CB47C59515C0538700E068C7 /* Frameworks */,
CB47C59615C0538700E068C7 /* Resources */,
CB47C5E215C0858300E068C7 /* Copy EditorConfig-core License */,
CB47C5E215C0858300E068C7 /* Copy Library Licenses */,
CB47C5E715C0875A00E068C7 /* CopyFiles */,
);
buildRules = (
Expand Down Expand Up @@ -296,19 +296,19 @@
shellPath = /bin/sh;
shellScript = "echo \"Killing TextMate...\"\nkillall TextMate\n\necho \"Installing PlugIn...\"\ncp -r \"$BUILT_PRODUCTS_DIR/\"*.tmplugin \"$USER_LIBRARY_DIR/Application Support/TextMate/PlugIns/\"";
};
CB47C5E215C0858300E068C7 /* Copy EditorConfig-core License */ = {
CB47C5E215C0858300E068C7 /* Copy Library Licenses */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Copy EditorConfig-core License";
name = "Copy Library Licenses";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "cp \"$SRCROOT/lib/editorconfig-core/LICENSE\" \"$BUILT_PRODUCTS_DIR/$WRAPPER_NAME/Contents/LICENSE-editorconfig-core\"";
shellScript = "cp \"$SRCROOT/lib/editorconfig-core/LICENSE\" \"$BUILT_PRODUCTS_DIR/$WRAPPER_NAME/Contents/LICENSE-editorconfig-core\"\ncp \"$SRCROOT/lib/pcre/LICENCE\" \"$BUILT_PRODUCTS_DIR/$WRAPPER_NAME/Contents/LICENSE-pcre\"\n";
};
CB60467916F6B558004753CD /* ShellScript */ = {
isa = PBXShellScriptBuildPhase;
Expand Down Expand Up @@ -427,7 +427,6 @@
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"$(BUILT_PRODUCTS_DIR)/editorconfig/**",
"\"$(SRCROOT)/../../../Library/Developer/Xcode/DerivedData/editorconfig-textmate-adijvhmrqyolxzdejpcjixnqjstl/Build/Products/Debug/editorconfig\"",
"$(PROJECT_DIR)/lib",
);
ONLY_ACTIVE_ARCH = NO;
Expand All @@ -448,7 +447,6 @@
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"$(BUILT_PRODUCTS_DIR)/editorconfig/**",
"\"$(SRCROOT)/../../../Library/Developer/Xcode/DerivedData/editorconfig-textmate-adijvhmrqyolxzdejpcjixnqjstl/Build/Products/Debug/editorconfig\"",
"$(PROJECT_DIR)/lib",
);
ONLY_ACTIVE_ARCH = NO;
Expand Down
2 changes: 1 addition & 1 deletion editorconfig-textmate/editorconfig-textmate-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<key>CFBundleVersion</key>
<string>0.2.4</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2012-2014 Rob Brackett. All rights reserved.</string>
<string>Copyright © 2012-2016 Rob Brackett. This is open source software and released under the MIT license.</string>
<key>NSPrincipalClass</key>
<string>ECEditorConfig</string>
<key>TMPlugInAPIVersion</key>
Expand Down
2 changes: 1 addition & 1 deletion lib/editorconfig-core
93 changes: 93 additions & 0 deletions lib/pcre/LICENCE
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
PCRE LICENCE
------------

PCRE is a library of functions to support regular expressions whose syntax
and semantics are as close as possible to those of the Perl 5 language.

Release 8 of PCRE is distributed under the terms of the "BSD" licence, as
specified below. The documentation for PCRE, supplied in the "doc"
directory, is distributed under the same terms as the software itself. The data
in the testdata directory is not copyrighted and is in the public domain.

The basic library functions are written in C and are freestanding. Also
included in the distribution is a set of C++ wrapper functions, and a
just-in-time compiler that can be used to optimize pattern matching. These
are both optional features that can be omitted when the library is built.


THE BASIC LIBRARY FUNCTIONS
---------------------------

Written by: Philip Hazel
Email local part: ph10
Email domain: cam.ac.uk

University of Cambridge Computing Service,
Cambridge, England.

Copyright (c) 1997-2015 University of Cambridge
All rights reserved.


PCRE JUST-IN-TIME COMPILATION SUPPORT
-------------------------------------

Written by: Zoltan Herczeg
Email local part: hzmester
Emain domain: freemail.hu

Copyright(c) 2010-2015 Zoltan Herczeg
All rights reserved.


STACK-LESS JUST-IN-TIME COMPILER
--------------------------------

Written by: Zoltan Herczeg
Email local part: hzmester
Emain domain: freemail.hu

Copyright(c) 2009-2015 Zoltan Herczeg
All rights reserved.


THE C++ WRAPPER FUNCTIONS
-------------------------

Contributed by: Google Inc.

Copyright (c) 2007-2012, Google Inc.
All rights reserved.


THE "BSD" LICENCE
-----------------

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.

* Neither the name of the University of Cambridge nor the name of Google
Inc. nor the names of their contributors may be used to endorse or
promote products derived from this software without specific prior
written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.

End
4 changes: 2 additions & 2 deletions lib/pcre/include/pcre.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ POSSIBILITY OF SUCH DAMAGE.
/* The current PCRE version information. */

#define PCRE_MAJOR 8
#define PCRE_MINOR 36
#define PCRE_MINOR 38
#define PCRE_PRERELEASE
#define PCRE_DATE 2014-09-26
#define PCRE_DATE 2015-11-23

/* When an application links to a PCRE DLL in Windows, the symbols that are
imported have to be identified as such. When building PCRE, the appropriate
Expand Down
Binary file modified lib/pcre/libpcre.a
Binary file not shown.
5 changes: 3 additions & 2 deletions source/ECConstants.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
// ECConstants.h
// editorconfig-textmate
//
// Created by Rob Brackett on 7/25/12.
// Copyright (c) 2012 Rob Brackett. All rights reserved.
// Copyright (c) 2012-2016 Rob Brackett.
// This is open source software, released under the MIT license;
// see the file LICENSE for details.
//

#import <Foundation/Foundation.h>
Expand Down
5 changes: 3 additions & 2 deletions source/ECConstants.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
// ECConstants.m
// editorconfig-textmate
//
// Created by Rob Brackett on 7/25/12.
// Copyright (c) 2012 Rob Brackett. All rights reserved.
// Copyright (c) 2012-2016 Rob Brackett.
// This is open source software, released under the MIT license;
// see the file LICENSE for details.
//

#import "ECConstants.h"
Expand Down
5 changes: 3 additions & 2 deletions source/ECEditorConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
// EditorConfig.h
// editorconfig-textmate
//
// Created by Rob Brackett on 7/25/12.
// Copyright (c) 2012 Rob Brackett. All rights reserved.
// Copyright (c) 2012-2016 Rob Brackett.
// This is open source software, released under the MIT license;
// see the file LICENSE for details.
//

#import <Cocoa/Cocoa.h>
Expand Down
19 changes: 16 additions & 3 deletions source/ECEditorConfig.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
// EditorConfig.m
// editorconfig-textmate
//
// Created by Rob Brackett on 7/25/12.
// Copyright (c) 2012 Rob Brackett. All rights reserved.
// Copyright (c) 2012-2016 Rob Brackett.
// This is open source software, released under the MIT license;
// see the file LICENSE for details.
//

#import <editorconfig/editorconfig_handle.h>
Expand All @@ -19,6 +20,7 @@ - (void)windowDocumentDidChange:(NSNotification *)notification;
- (void)textViewDidSetDocument:(NSNotification *)notification;

- (void)updateWindow:(NSWindow *)window withConfig:(NSDictionary *)config;
- (NSString *)editorConfigCoreVersion;

@end

Expand All @@ -29,7 +31,9 @@ @implementation ECEditorConfig

- (id)initWithPlugInController:(id <TMPlugInController>)aController {
if(self = [self init]) {
DebugLog(@"Initializing EditorConfig-TextMate for TextMate %f.", aController.version);
DebugLog(@"Initializing EditorConfig-TextMate for TextMate %f with EditorConfig-Core %@.",
aController.version,
[self editorConfigCoreVersion]);

if (aController.version < 2.0) {
// Make the window fire a notification when a new document is shown
Expand Down Expand Up @@ -124,4 +128,13 @@ - (void)updateWindow:(NSWindow *)window withConfig:(NSDictionary *)config {
// TODO: end_of_line support
}

- (NSString *)editorConfigCoreVersion {
int ec_version_major, ec_version_minor, ec_version_patch;
editorconfig_get_version(&ec_version_major,
&ec_version_minor,
&ec_version_patch);
return [NSString stringWithFormat:@"%d.%d.%d",
ec_version_major, ec_version_minor, ec_version_patch];
}

@end
5 changes: 3 additions & 2 deletions source/TMPlugInController.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
// TMPlugInController.h
// editorconfig-textmate
//
// Created by Rob Brackett on 7/25/12.
// Copyright (c) 2012 Rob Brackett. All rights reserved.
// Copyright (c) 2012-2016 Rob Brackett.
// This is open source software, released under the MIT license;
// see the file LICENSE for details.
//

#import <Foundation/Foundation.h>
Expand Down

0 comments on commit ed84b9b

Please sign in to comment.