Skip to content

Commit c877c2b

Browse files
committed
[skip ci] Add conanfile.py, edit it from script/update-version.py
1 parent 82afbe3 commit c877c2b

File tree

3 files changed

+27
-0
lines changed

3 files changed

+27
-0
lines changed

conanfile.py

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
from conans import ConanFile
2+
3+
class StringViewLiteConan(ConanFile):
4+
version = "0.0.0"
5+
name = "string-view-lite"
6+
description = "string-view"
7+
license = "Boost Software License - Version 1.0. http://www.boost.org/LICENSE_1_0.txt"
8+
url = "https://github.com/martinmoene/string-view-lite.git"
9+
exports_sources = "include/nonstd/*", "LICENSE.txt"
10+
build_policy = "missing"
11+
author = "Martin Moene"
12+
13+
def build(self):
14+
"""Avoid warning on build step"""
15+
pass
16+
17+
def package(self):
18+
"""Provide pkg/include/nonstd/*.hpp"""
19+
self.copy("*.hpp")
20+
21+
def package_info(self):
22+
self.info.header_only()

project/CodeBlocks/string-view-lite.cbp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
<Unit filename="../../LICENSE.txt" />
1919
<Unit filename="../../README.md" />
2020
<Unit filename="../../appveyor.yml" />
21+
<Unit filename="../../conanfile.py" />
2122
<Unit filename="../../example/01-basic.cpp" />
2223
<Unit filename="../../include/nonstd/string_view.hpp" />
2324
<Unit filename="../../script/update-version.py" />

script/update-version.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@
3131
# , r'\string_view_lite_version\s+=\s+"([0-9]+\.[0-9]+\.[0-9]+)"\s*$'
3232
# , 'string_view_lite_version = "{major}.{minor}.{patch}"\n' )
3333

34+
, ( 'conanfile.py'
35+
, r'version\s+=\s+"([0-9]+\.[0-9]+\.[0-9]+)"\s*$'
36+
, 'version = "{major}.{minor}.{patch}"' )
37+
3438
, ( 'include/nonstd/string_view.hpp'
3539
, r'\#define\s+string_view_lite_MAJOR\s+[0-9]+\s*$'
3640
, '#define string_view_lite_MAJOR {major}' )

0 commit comments

Comments
 (0)