Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
GMPhobos
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
GMPhobos
Commits
3e419211
Commit
3e419211
authored
Sep 05, 2017
by
翟国钧
Browse files
Options
Browse Files
Download
Plain Diff
解决冲突
parents
6cf2972e
6e44d469
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
40 additions
and
40 deletions
+40
-40
GMViewController.m
Example/GMPhobos/GMViewController.m
+11
-1
Podfile.lock
Example/Podfile.lock
+2
-2
GMPhobos.podspec.json
Example/Pods/Local Podspecs/GMPhobos.podspec.json
+2
-2
Manifest.lock
Example/Pods/Manifest.lock
+2
-2
Info.plist
Example/Pods/Target Support Files/GMPhobos/Info.plist
+1
-1
GMPhobos.podspec
GMPhobos.podspec
+1
-1
Phobos.h
Pod/Classes/Phobos.h
+4
-0
Phobos.m
Pod/Classes/Phobos.m
+2
-10
PhobosUtil.m
Pod/Classes/PhobosUtil.m
+2
-8
report.xml
fastlane/report.xml
+13
-13
No files found.
Example/GMPhobos/GMViewController.m
View file @
3e419211
...
@@ -18,9 +18,19 @@
...
@@ -18,9 +18,19 @@
-
(
void
)
viewDidLoad
-
(
void
)
viewDidLoad
{
{
[
super
viewDidLoad
];
[
super
viewDidLoad
];
#ifdef POD_CONFIGURATION_APP_STORE
NSString
*
url
=
@"http://log.gmei.com/log/collect"
;
#elif POD_CONFIGURATION_UNIT_TEST
NSString
*
url
=
@"http://jaguar.gmei/log/collect"
;
#else
NSString
*
url
=
@"http://log.test.gengmei.cc/log/collect"
;
#endif
[
Phobos
sharedClient
].
serverAPI
=
url
;
}
}
-
(
void
)
didReceiveMemoryWarning
-
(
void
)
didReceiveMemoryWarning
{
{
[
super
didReceiveMemoryWarning
];
[
super
didReceiveMemoryWarning
];
...
...
Example/Podfile.lock
View file @
3e419211
PODS:
PODS:
- GMCache (0.1.1):
- GMCache (0.1.1):
- TMCache (~> 2.1.0)
- TMCache (~> 2.1.0)
- GMPhobos (0.4.
0
):
- GMPhobos (0.4.
1
):
- GMCache (~> 0.1.1)
- GMCache (~> 0.1.1)
- TMCache (2.1.0)
- TMCache (2.1.0)
...
@@ -14,7 +14,7 @@ EXTERNAL SOURCES:
...
@@ -14,7 +14,7 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
SPEC CHECKSUMS:
GMCache: 73855b613b9d7e34f4f37ad425e8b8153b760c04
GMCache: 73855b613b9d7e34f4f37ad425e8b8153b760c04
GMPhobos:
911b4e3ee75b65dd1e3196a7d05e684134cee63d
GMPhobos:
2fd07df959c1c5f773a3e2355930fcbcf4ddf38c
TMCache: 95ebcc9b3c7e90fb5fd8fc3036cba3aa781c9bed
TMCache: 95ebcc9b3c7e90fb5fd8fc3036cba3aa781c9bed
PODFILE CHECKSUM: 281ed5ce2f0e8e2e49cc13b1e4726e6686ac6095
PODFILE CHECKSUM: 281ed5ce2f0e8e2e49cc13b1e4726e6686ac6095
...
...
Example/Pods/Local Podspecs/GMPhobos.podspec.json
View file @
3e419211
{
{
"name"
:
"GMPhobos"
,
"name"
:
"GMPhobos"
,
"version"
:
"0.4.
0
"
,
"version"
:
"0.4.
1
"
,
"summary"
:
"GM statistic data sdk"
,
"summary"
:
"GM statistic data sdk"
,
"description"
:
"GM event track sdk."
,
"description"
:
"GM event track sdk."
,
"homepage"
:
"http://git.gengmei.cc/gengmeiios/GMPhobos"
,
"homepage"
:
"http://git.gengmei.cc/gengmeiios/GMPhobos"
,
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
},
},
"source"
:
{
"source"
:
{
"git"
:
"git@git.gengmei.cc:gengmeiios/GMPhobos.git"
,
"git"
:
"git@git.gengmei.cc:gengmeiios/GMPhobos.git"
,
"tag"
:
"0.4.
0
"
"tag"
:
"0.4.
1
"
},
},
"platforms"
:
{
"platforms"
:
{
"ios"
:
"8.0"
"ios"
:
"8.0"
...
...
Example/Pods/Manifest.lock
View file @
3e419211
PODS:
PODS:
- GMCache (0.1.1):
- GMCache (0.1.1):
- TMCache (~> 2.1.0)
- TMCache (~> 2.1.0)
- GMPhobos (0.4.
0
):
- GMPhobos (0.4.
1
):
- GMCache (~> 0.1.1)
- GMCache (~> 0.1.1)
- TMCache (2.1.0)
- TMCache (2.1.0)
...
@@ -14,7 +14,7 @@ EXTERNAL SOURCES:
...
@@ -14,7 +14,7 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
SPEC CHECKSUMS:
GMCache: 73855b613b9d7e34f4f37ad425e8b8153b760c04
GMCache: 73855b613b9d7e34f4f37ad425e8b8153b760c04
GMPhobos:
911b4e3ee75b65dd1e3196a7d05e684134cee63d
GMPhobos:
2fd07df959c1c5f773a3e2355930fcbcf4ddf38c
TMCache: 95ebcc9b3c7e90fb5fd8fc3036cba3aa781c9bed
TMCache: 95ebcc9b3c7e90fb5fd8fc3036cba3aa781c9bed
PODFILE CHECKSUM: 281ed5ce2f0e8e2e49cc13b1e4726e6686ac6095
PODFILE CHECKSUM: 281ed5ce2f0e8e2e49cc13b1e4726e6686ac6095
...
...
Example/Pods/Target Support Files/GMPhobos/Info.plist
View file @
3e419211
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
<
k
e
y
>
CFBundlePackageType
<
/k
e
y
>
<
k
e
y
>
CFBundlePackageType
<
/k
e
y
>
<
string
>
FMWK
<
/string
>
<
string
>
FMWK
<
/string
>
<
k
e
y
>
CFBundleShortVersionString
<
/k
e
y
>
<
k
e
y
>
CFBundleShortVersionString
<
/k
e
y
>
<
string
>
0.4.
0
<
/string
>
<
string
>
0.4.
1
<
/string
>
<
k
e
y
>
CFBundleSignature
<
/k
e
y
>
<
k
e
y
>
CFBundleSignature
<
/k
e
y
>
<
string
>
????
<
/string
>
<
string
>
????
<
/string
>
<
k
e
y
>
CFBundleVersion
<
/k
e
y
>
<
k
e
y
>
CFBundleVersion
<
/k
e
y
>
...
...
GMPhobos.podspec
View file @
3e419211
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
Pod
::
Spec
.
new
do
|
s
|
Pod
::
Spec
.
new
do
|
s
|
s
.
name
=
"
GMPhobos
"
s
.
name
=
"
GMPhobos
"
s
.
version
=
"0.4.
1
"
s
.
version
=
"0.4.
2
"
s
.
summary
=
"GM statistic data sdk"
s
.
summary
=
"GM statistic data sdk"
s
.
description
=
<<-
DESC
s
.
description
=
<<-
DESC
...
...
Pod/Classes/Phobos.h
View file @
3e419211
...
@@ -76,6 +76,10 @@
...
@@ -76,6 +76,10 @@
*/
*/
@property
(
strong
,
nonatomic
)
NSMutableDictionary
*
userType
;
@property
(
strong
,
nonatomic
)
NSMutableDictionary
*
userType
;
/**
数据接收的服务器API
*/
@property
(
copy
,
nonatomic
)
NSString
*
serverAPI
;
#pragma mark - 事件采集
#pragma mark - 事件采集
/**
/**
...
...
Pod/Classes/Phobos.m
View file @
3e419211
...
@@ -52,6 +52,7 @@ static NSString *sdkVersion = @"110";
...
@@ -52,6 +52,7 @@ static NSString *sdkVersion = @"110";
_userId
=
0
;
_userId
=
0
;
_netStatus
=
@""
;
_netStatus
=
@""
;
_currentCityId
=
@""
;
_currentCityId
=
@""
;
_serverAPI
=
@""
;
_userType
=
[[
NSMutableDictionary
alloc
]
initWithCapacity
:
0
];
_userType
=
[[
NSMutableDictionary
alloc
]
initWithCapacity
:
0
];
_appVersion
=
[
PhobosUtil
getAppVersion
];
_appVersion
=
[
PhobosUtil
getAppVersion
];
[
self
setupNotification
];
[
self
setupNotification
];
...
@@ -156,8 +157,6 @@ static NSString *sdkVersion = @"110";
...
@@ -156,8 +157,6 @@ static NSString *sdkVersion = @"110";
/**
/**
* @brief 应用打开时的处理
* @brief 应用打开时的处理
*
*
* @param sender
*
* @since 0.0.1
* @since 0.0.1
*/
*/
-
(
void
)
handleAppFinishLaunch
:
(
id
)
sender
{
-
(
void
)
handleAppFinishLaunch
:
(
id
)
sender
{
...
@@ -169,8 +168,6 @@ static NSString *sdkVersion = @"110";
...
@@ -169,8 +168,6 @@ static NSString *sdkVersion = @"110";
/**
/**
* @brief 应用进入前台的处理
* @brief 应用进入前台的处理
*
*
* @param sender
*
* @since 0.0.1
* @since 0.0.1
*/
*/
-
(
void
)
handleAppInForeground
:
(
id
)
sender
{
-
(
void
)
handleAppInForeground
:
(
id
)
sender
{
...
@@ -183,9 +180,6 @@ static NSString *sdkVersion = @"110";
...
@@ -183,9 +180,6 @@ static NSString *sdkVersion = @"110";
/**
/**
* @brief 应用进入后台的处理
* @brief 应用进入后台的处理
*
* @param sender
*
* @since 0.0.1
* @since 0.0.1
*/
*/
-
(
void
)
handleAppInBackgound
:
(
id
)
sender
{
-
(
void
)
handleAppInBackgound
:
(
id
)
sender
{
...
@@ -346,8 +340,6 @@ static NSString *sdkVersion = @"110";
...
@@ -346,8 +340,6 @@ static NSString *sdkVersion = @"110";
/**
/**
* @brief 将埋点时间封装成词典数据
* @brief 将埋点时间封装成词典数据
*
*
* @return
*
* @since 0.0.1
* @since 0.0.1
*/
*/
-
(
NSDictionary
*
)
prepareDictionaryForEvent
:
(
NSString
*
)
eventId
attributes
:
(
NSDictionary
*
)
attributes
{
-
(
NSDictionary
*
)
prepareDictionaryForEvent
:
(
NSString
*
)
eventId
attributes
:
(
NSDictionary
*
)
attributes
{
...
@@ -449,7 +441,7 @@ static NSString *sdkVersion = @"110";
...
@@ -449,7 +441,7 @@ static NSString *sdkVersion = @"110";
让sendArray方法负责发送,数据一旦转移到缓存区,就把原有的数据干掉。
让sendArray方法负责发送,数据一旦转移到缓存区,就把原有的数据干掉。
@author zhaiguojun 16-10-17 in (null)
@author zhaiguojun 16-10-17 in (null)
@param array 参数
@param array 参数
@param
now
是否立即清楚缓存
@param
clean
是否立即清楚缓存
*/
*/
-
(
void
)
sendArray
:
(
NSArray
*
)
array
cleanCacheRightNow
:
(
BOOL
)
clean
{
-
(
void
)
sendArray
:
(
NSArray
*
)
array
cleanCacheRightNow
:
(
BOOL
)
clean
{
@try
{
@try
{
...
...
Pod/Classes/PhobosUtil.m
View file @
3e419211
...
@@ -20,6 +20,7 @@
...
@@ -20,6 +20,7 @@
#import <sys/sysctl.h>
#import <sys/sysctl.h>
#import <mach/machine.h>
#import <mach/machine.h>
#import "sys/utsname.h"
#import "sys/utsname.h"
#import "Phobos.h"
#define IOS_CELLULAR @"pdp_ip0"
#define IOS_CELLULAR @"pdp_ip0"
#define IOS_WIFI @"en0"
#define IOS_WIFI @"en0"
...
@@ -112,15 +113,8 @@
...
@@ -112,15 +113,8 @@
}
}
+
(
void
)
sendData
:(
NSData
*
)
data
success
:(
SendDataSuccessBlock
)
success
{
+
(
void
)
sendData
:(
NSData
*
)
data
success
:(
SendDataSuccessBlock
)
success
{
#ifdef POD_CONFIGURATION_APP_STORE
NSString
*
url
=
@"http://log.gmei.com/log/collect"
;
#elif POD_CONFIGURATION_UNIT_TEST
NSString
*
url
=
@"http://jaguar.gmei/log/collect"
;
#else
NSString
*
url
=
@"http://log.test.gengmei.cc/log/collect"
;
#endif
@try
{
@try
{
NSMutableURLRequest
*
request
=
[[
NSMutableURLRequest
alloc
]
initWithURL
:[
NSURL
URLWithString
:
url
]];
NSMutableURLRequest
*
request
=
[[
NSMutableURLRequest
alloc
]
initWithURL
:[
NSURL
URLWithString
:
[
Phobos
sharedClient
].
serverAPI
]];
[
request
setValue
:
@"gzip"
forHTTPHeaderField
:
@"Content-Encoding"
];
[
request
setValue
:
@"gzip"
forHTTPHeaderField
:
@"Content-Encoding"
];
request
.
HTTPBody
=
data
;
request
.
HTTPBody
=
data
;
request
.
HTTPMethod
=
@"POST"
;
request
.
HTTPMethod
=
@"POST"
;
...
...
fastlane/report.xml
View file @
3e419211
...
@@ -5,67 +5,67 @@
...
@@ -5,67 +5,67 @@
<testcase
classname=
"fastlane.lanes"
name=
"00: Verifying required fastlane version"
time=
"0.00
2012
"
>
<testcase
classname=
"fastlane.lanes"
name=
"00: Verifying required fastlane version"
time=
"0.00
1983
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"01: default_platform"
time=
"0.001
72
"
>
<testcase
classname=
"fastlane.lanes"
name=
"01: default_platform"
time=
"0.001
661
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"02: import_from_git"
time=
"
0.59273
2"
>
<testcase
classname=
"fastlane.lanes"
name=
"02: import_from_git"
time=
"
2.56905
2"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"03: git_pull"
time=
"
0.957899
"
>
<testcase
classname=
"fastlane.lanes"
name=
"03: git_pull"
time=
"
4.603808
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"04: ensure_git_branch"
time=
"0.01
033
"
>
<testcase
classname=
"fastlane.lanes"
name=
"04: ensure_git_branch"
time=
"0.01
1
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"05: pod_install"
time=
"22.
882175
"
>
<testcase
classname=
"fastlane.lanes"
name=
"05: pod_install"
time=
"22.
712397
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"06: pod_lib_lint"
time=
"
21.766492
"
>
<testcase
classname=
"fastlane.lanes"
name=
"06: pod_lib_lint"
time=
"
31.332885
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"07: version_bump_podspec"
time=
"0.002
861
"
>
<testcase
classname=
"fastlane.lanes"
name=
"07: version_bump_podspec"
time=
"0.002
76
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"08: git_commit_all"
time=
"0.
090588
"
>
<testcase
classname=
"fastlane.lanes"
name=
"08: git_commit_all"
time=
"0.
107871
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"09: add_git_tag"
time=
"0.01
9525
"
>
<testcase
classname=
"fastlane.lanes"
name=
"09: add_git_tag"
time=
"0.01
7011
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"10: push_to_git_remote"
time=
"
0.90996
9"
>
<testcase
classname=
"fastlane.lanes"
name=
"10: push_to_git_remote"
time=
"
2.78740
9"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"11: pod_push"
time=
"
8.571633
"
>
<testcase
classname=
"fastlane.lanes"
name=
"11: pod_push"
time=
"
10.396381
"
>
</testcase>
</testcase>
<testcase
classname=
"fastlane.lanes"
name=
"12: pod_repo_update"
time=
"9.
360721
"
>
<testcase
classname=
"fastlane.lanes"
name=
"12: pod_repo_update"
time=
"9.
979275
"
>
</testcase>
</testcase>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment