Allow examples to build outside mastodonpp.
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
9bc3fe6fe2
commit
161554e677
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Print information about an instance (/api/v1/instance).
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
|
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Print new public events (/api/v1/streaming/public).
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <chrono>
|
||||
#include <iostream>
|
||||
|
|
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Post a status (/api/v1/status).
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
|
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Post a status (/api/v1/status) with an attachment (/api/v1/media).
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
|
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Update notification settings (/api/pleroma/notification_settings).
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
|
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Update account display name settings (/api/v1/accounts/update_credentials).
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
|
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Post a status (/api/v1/status), then delete it (/api/v1/statuses/:id).
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <chrono>
|
||||
#include <iostream>
|
||||
|
|
|
@ -15,7 +15,11 @@
|
|||
|
||||
// Obtain an access token and verify that it works.
|
||||
|
||||
#include "mastodonpp.hpp"
|
||||
#if __has_include("mastodonpp.hpp")
|
||||
# include "mastodonpp.hpp" // We're building mastodonpp.
|
||||
#else
|
||||
# include <mastodonpp/mastodonpp.hpp> // We're building outside mastodonpp.
|
||||
#endif
|
||||
|
||||
#include <cstdlib>
|
||||
#include <iostream>
|
||||
|
|
Loading…
Reference in New Issue
Block a user