#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4")
const double PI = acos(-1.0);
const int DIR = 4;
const int X[] = {1, 0, -1, 0};
const int Y[] = {0, 1, 0, -1};
const int N = (int)1e6 + 228;
using namespace std;
struct Node {
  int sz = 1, x = 0, y;
  Node *l = NULL, *r = NULL;
  Node() {}
  Node(int _sz) : sz(_sz), x(0), y(rand()) {}
};
int sz(Node* t) {
  if (!t) return 0;
  return t->sz;
}
void upd(Node* t) {
  if (!t) return;
  t->sz = 1 + sz(t->l) + sz(t->r);
}
void split(Node* t, int k, Node*& l, Node*& r) {
  if (!t) {
    l = r = NULL;
    return;
  }
  if (sz(t->l) >= k) {
    split(t->l, k, l, t->l);
    r = t;
  } else {
    split(t->r, k - sz(t->l) - 1, t->r, r);
    l = t;
  }
  upd(l), upd(r);
}
void merge(Node*& t, Node* l, Node* r) {
  if (!l) {
    t = r;
    return;
  }
  if (!r) {
    t = l;
    return;
  }
  if (l->y > r->y) {
    merge(l->r, l->r, r);
    t = l;
  } else {
    merge(r->l, l, r->l);
    t = r;
  }
  upd(t);
}
int n, m, x[N], y[N];
bool was[N];
vector<int> v;
void dfs(Node* t) {
  if (!t) return;
  dfs(t->l);
  if (t->x && was[t->x]) {
    cout << -1 << endl;
    exit(0);
  }
  was[t->x] = true;
  dfs(t->r);
}
void dfs1(Node* t) {
  if (!t) return;
  dfs1(t->l);
  if (t->x)
    printf("%d ", t->x);
  else {
    printf("%d ", v.back());
    v.pop_back();
  }
  dfs1(t->r);
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= m; i++) {
    scanf("%d%d", &x[i], &y[i]);
  }
  Node* t = NULL;
  for (int i = 1; i <= n; i++) {
    Node* a = new Node(1);
    merge(t, t, a);
  }
  for (int i = m; i >= 1; i--) {
    Node *a, *b;
    split(t, 1, a, b);
    if (a->x == 0)
      a->x = x[i];
    else if (a->x != x[i]) {
      cout << -1 << endl;
      return 0;
    }
    Node* c;
    split(b, y[i] - 1, b, c);
    merge(t, b, a);
    merge(t, t, c);
  }
  dfs(t);
  for (int i = 1; i <= n; i++)
    if (!was[i]) v.push_back(i);
  reverse(v.begin(), v.end());
  dfs1(t);
  return 0;
}
